[glib/glib-2-58: 2/6] gspawn: Fix build on systems without O_CLOEXEC
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib/glib-2-58: 2/6] gspawn: Fix build on systems without O_CLOEXEC
- Date: Wed, 5 Sep 2018 10:11:19 +0000 (UTC)
commit b8a4754d59189a57c1e576cf1404ea4f96cd27e8
Author: Ryan Schmidt <git ryandesign com>
Date: Thu Aug 30 18:04:35 2018 -0500
gspawn: Fix build on systems without O_CLOEXEC
Fixes typo introduced in 4afe429d7ce4d813e0b263fd3eab9e543f11d2a6.
See https://gitlab.gnome.org/GNOME/glib/issues/1488
glib/gspawn.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/glib/gspawn.c b/glib/gspawn.c
index e273e2a99..5d0c29d70 100644
--- a/glib/gspawn.c
+++ b/glib/gspawn.c
@@ -1485,7 +1485,7 @@ do_posix_spawn (gchar **argv,
parent_close_fds[num_parent_close_fds++] = write_null;
#ifndef HAVE_O_CLOEXEC
- fcntl (read_null, F_SETFD, FD_CLOEXEC);
+ fcntl (write_null, F_SETFD, FD_CLOEXEC);
#endif
r = posix_spawn_file_actions_adddup2 (&file_actions, write_null, 1);
@@ -1509,7 +1509,7 @@ do_posix_spawn (gchar **argv,
parent_close_fds[num_parent_close_fds++] = write_null;
#ifndef HAVE_O_CLOEXEC
- fcntl (read_null, F_SETFD, FD_CLOEXEC);
+ fcntl (write_null, F_SETFD, FD_CLOEXEC);
#endif
r = posix_spawn_file_actions_adddup2 (&file_actions, write_null, 2);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]