On Tue, Jan 17, 2012 at 10:18:34AM -0200, Luiz Capitulino wrote: > On Mon, 16 Jan 2012 21:06:27 +0000 > "Daniel P. Berrange" <berra...@redhat.com> wrote: > > > + has_pmutils = find_executable_file(pmutils_bin, pmutils_path, > > > + sizeof(pmutils_path)); > > > + > > > + pid = fork(); > > > + if (pid == 0) { > > > + /* child */ > > > + int fd; > > > + const char *cmd; > > > + > > > + setsid(); > > > + reopen_fd_to_null(0); > > > + reopen_fd_to_null(1); > > > + reopen_fd_to_null(2); > > > + > > > + if (has_pmutils) { > > > + execle(pmutils_path, pmutils_bin, NULL, environ); > > > > You could just use execl() and drop the trailing 'environ' here, > > since that is the default anyway. > > execl() is not in the async-signal-safe list.
It was not in POSIX.1-2004, but POSIX.1-2008 added it. I don't thing this is worth arguing over though, so just leave it as you have :-) Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|