<i>possible to have an empty info nameofexecutable</i> status still Open with 4 other changes
by
.
D 2011-10-12T16:49:56
J icomment Doing\sa\sreadlink()\son\s/proc/[pid]/exe\sis\selegant,\sbut\swon't\swork\son\sOSX.\sThere,\sthe\sonly\sreliable\smethod\sI've\sfound\sfor\sgetting\sthe\sexecutable\spath\sfrom\sthe\sPID\sis\sby\scalling\slsof\sin\sa\ssubprocess:\n\n\s\slsof\s-a\s-p\s[pid]\s-F\sn\s-d\stxt\n\nThen\syou\sneed\sthe\sfirst\sline\sthat\sstarts\swith\s'n',\sand\syou\sneed\sall\sof\sthat\sline\sexcept\sthe\sfirst\scharacter.\sUgh.\sWorks\sthough.\s(Poking\sin\sthe\snormal\ssystem\sprocess\sinformation\sdoesn't\swork;\sthat\sgives\syou\sthe\sprocess\sname\swithout\sthe\spath\sto\sit.)\n
J login dkf
J mimetype text/plain
J username dkf
K 1224888fffffffffffffffffffffffffffffffff
U dkf
Z 19cbad3ced93125a57cfaa961d0fede1