1

I am trying to do ps -A in code, but typing execlp("/bin/ps", "ps", "-A", NULL); outputs:

/bin/ps: No such file or directory

But I can see ps in the file directory so I have no idea what is wrong.

atg
  • 127
  • 2
  • 13

0 Answers0