Get other process' argv in OS X using C

后端 未结 2 1432
醉梦人生
醉梦人生 2020-11-30 11:55

I want to get other process\' argv like ps.

I\'m using Mac OS X 10.4.11 running on Intel or PowerPC.

First, I read code of ps and man kvm, then I wrote some

2条回答
  •  暖寄归人
    2020-11-30 12:49

    In 10.6, KERN_PROCARGS2 is available: https://gist.github.com/770696

    This way is used from ps, procfs on MacFUSE, etc.

提交回复
热议问题