diff options
| author | Paul Eggert | 2013-07-16 00:05:41 -0700 |
|---|---|---|
| committer | Paul Eggert | 2013-07-16 00:05:41 -0700 |
| commit | c7ddc792b747fdf4fde822df0cf9c7b712be4219 (patch) | |
| tree | de532bf42e3675fa093996b13ddb490cb8ec2f6c /src/emacs.c | |
| parent | e6c005c5f8e39252fd11821b6452843bead2df6a (diff) | |
| download | emacs-c7ddc792b747fdf4fde822df0cf9c7b712be4219.tar.gz emacs-c7ddc792b747fdf4fde822df0cf9c7b712be4219.zip | |
Fix porting bug to older POSIXish platforms.
* sysdep.c (emacs_pipe): New function, that implements
pipe2 (fd, O_CLOEXEC) even on hosts that lack O_CLOEXEC.
This should port better to CentOS 5 and to Mac OS X 10.6.
All calls to pipe2 changed.
Fixes: debbugs:14862
Diffstat (limited to 'src/emacs.c')
| -rw-r--r-- | src/emacs.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/emacs.c b/src/emacs.c index 7ad9739530b..cf3a3c68932 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -985,7 +985,7 @@ main (int argc, char **argv) | |||
| 985 | use a pipe for synchronization. The parent waits for the child | 985 | use a pipe for synchronization. The parent waits for the child |
| 986 | to close its end of the pipe (using `daemon-initialized') | 986 | to close its end of the pipe (using `daemon-initialized') |
| 987 | before exiting. */ | 987 | before exiting. */ |
| 988 | if (pipe2 (daemon_pipe, O_CLOEXEC) != 0) | 988 | if (emacs_pipe (daemon_pipe) != 0) |
| 989 | { | 989 | { |
| 990 | fprintf (stderr, "Cannot pipe!\n"); | 990 | fprintf (stderr, "Cannot pipe!\n"); |
| 991 | exit (1); | 991 | exit (1); |