Hello,
I execute a system(..) command and this returns a value which I want to save in a variable.
I want to save the PID of tcpdump into a variable to use this PID later in my C programme. Is there a possibility to do this?Code:err = system("rsh -l root 172.16.100.144 pidof tcpdump");
I know an indirect way with redirecting the output into a file and read this file later. But this is no acceptable solution.