Number of Running Processes on a Minix system from C code

前端 未结 8 1059
盖世英雄少女心
盖世英雄少女心 2021-01-03 06:14

So, this seemed simple at first, but after crawling Google and here, the answer doesn\'t seem as simple as I first thought.

Basically, I\'m editing a MINIX kernel as

8条回答
  •  时光取名叫无心
    2021-01-03 06:46

    Check this out: http://sourceforge.net/p/readproc/code/ci/master/tree/

    #include"read_proc.h"
    int main(void)
    {
         struct Root * root=read_proc();
         printf("%lu\n",root->len);
         return 0;
    }
    

提交回复
热议问题