Terminate the execl() argument list with (char *)NULL instead of 0.

The later is wrong and may fail on sizeof(char *) != sizeof(int)
machines. The patch has already been sent to and accepted by the
diffutils author, but the file is already off the vendor branch, so
correct it here in the meanwhile too.
This commit is contained in:
Hartmut Brandt 2003-11-03 12:41:27 +00:00
parent 34eee97206
commit b41f9c7d79

View File

@ -210,9 +210,9 @@ begin_output ()
close (pipes[0]);
}
#ifdef __FreeBSD__
execl (PR_PROGRAM, PR_PROGRAM, "-F", "-h", name, 0);
execl (PR_PROGRAM, PR_PROGRAM, "-F", "-h", name, (char *)NULL);
#else
execl (PR_PROGRAM, PR_PROGRAM, "-f", "-h", name, 0);
execl (PR_PROGRAM, PR_PROGRAM, "-f", "-h", name, (char *)NULL);
#endif
pfatal_with_name (PR_PROGRAM);
}