next up previous contents index
Next: file_select Up: Others Previous: cmd_shell

cmd_shell_to_string

  char * cmd_shell_to_string(char * cmd)

Executes sh -c cmd in a sub-shell and returns a new allocated string containing all the characters produced by the command cmd in the stdout or stderr.

Attention Be careful, the string is allocated each time the function is called, use free() to release it.



Lionel Fournigault
Fri Nov 6 17:00:30 MET 1998