Search Results

Search: Posts Made By: pludi
Forum: Programming 07-12-2010
19,700
Posted By pludi
From the man page of popen So any program...
From the man page of popen

So any program you could call usingsh -c "/path/to/program arg1 arg2 ... argn"can be called just the same.

Also, please make it a habit of reading the man pages first...
Forum: Programming 07-12-2010
19,700
Posted By pludi
Because system() does not return the output of a...
Because system() does not return the output of a script, but only the exit status. Eg. if instead of "./test" you'd run /bin/true (or /usr/bin/true), you'd always get 0, while with /bin/false you'd...
Forum: Programming 07-09-2010
19,700
Posted By pludi
Quick example, will copy the contents of the...
Quick example, will copy the contents of the files given on the command line to stdout, prefixed by the filename and the line number (yes, it's UUOC):#include <stdio.h>

int main(int argc, char...
Forum: Programming 07-09-2010
19,700
Posted By pludi
Start it using popen, and read from the returned...
Start it using popen, and read from the returned file descriptor as you would from any other.
Showing results 1 to 4 of 4

 
All times are GMT -4. The time now is 01:27 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy