……
The execv and execvp functions provide an array of pointers to null-terminated strings that represent the argument list available to the new program. The first argument, by convention, should point to the file name associated with the file being executed. The array of pointers must be terminated by a NULL pointer.
……作者: kj501 时间: 2003-04-17 23:10 标题: 请教在重定向标准输入、输出时,exec函数族调用的问题。 楼上的说得对,第二个参数还要是以NULL结尾的字符串数组。