From 19c69217984a9bedaccf1f494b6b06eaf932f6cc Mon Sep 17 00:00:00 2001 From: Federico Mena Quintero Date: Fri, 20 May 2005 19:30:02 +0000 Subject: [PATCH] Merged from glib-2-6: 2005-05-20 Federico Mena Quintero Merged from glib-2-6: * glib/gspawn.c (g_spawn_command_line_sync): Clarify the meaning of exit_status(); it's not the return code from the child, but rather the waitpid() status. --- ChangeLog | 8 ++++++++ ChangeLog.pre-2-10 | 8 ++++++++ ChangeLog.pre-2-12 | 8 ++++++++ ChangeLog.pre-2-8 | 8 ++++++++ glib/gspawn.c | 8 ++++++-- 5 files changed, 38 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2a69c1a1d..ad552745d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2005-05-20 Federico Mena Quintero + + Merged from glib-2-6: + + * glib/gspawn.c (g_spawn_command_line_sync): Clarify the meaning + of exit_status(); it's not the return code from the child, but + rather the waitpid() status. + 2005-05-18 Matthias Clasen * glib/gunidecomp.c: Correct the end of the Hangul diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 2a69c1a1d..ad552745d 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,11 @@ +2005-05-20 Federico Mena Quintero + + Merged from glib-2-6: + + * glib/gspawn.c (g_spawn_command_line_sync): Clarify the meaning + of exit_status(); it's not the return code from the child, but + rather the waitpid() status. + 2005-05-18 Matthias Clasen * glib/gunidecomp.c: Correct the end of the Hangul diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index 2a69c1a1d..ad552745d 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,3 +1,11 @@ +2005-05-20 Federico Mena Quintero + + Merged from glib-2-6: + + * glib/gspawn.c (g_spawn_command_line_sync): Clarify the meaning + of exit_status(); it's not the return code from the child, but + rather the waitpid() status. + 2005-05-18 Matthias Clasen * glib/gunidecomp.c: Correct the end of the Hangul diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 2a69c1a1d..ad552745d 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,11 @@ +2005-05-20 Federico Mena Quintero + + Merged from glib-2-6: + + * glib/gspawn.c (g_spawn_command_line_sync): Clarify the meaning + of exit_status(); it's not the return code from the child, but + rather the waitpid() status. + 2005-05-18 Matthias Clasen * glib/gunidecomp.c: Correct the end of the Hangul diff --git a/glib/gspawn.c b/glib/gspawn.c index 32f2f3a0e..48f321c1e 100644 --- a/glib/gspawn.c +++ b/glib/gspawn.c @@ -195,7 +195,7 @@ read_data (GString *str, * @user_data: user data for @child_setup * @standard_output: return location for child output * @standard_error: return location for child error messages - * @exit_status: child exit status, as returned by waitpid() + * @exit_status: return location for child exit status, as returned by waitpid() * @error: return location for error * * Executes a child synchronously (waits for the child to exit before returning). @@ -600,7 +600,7 @@ g_spawn_async_with_pipes (const gchar *working_directory, * @command_line: a command line * @standard_output: return location for child output * @standard_error: return location for child errors - * @exit_status: return location for child exit status + * @exit_status: return location for child exit status, as returned by waitpid() * @error: return location for errors * * A simple version of g_spawn_sync() with little-used parameters @@ -611,6 +611,10 @@ g_spawn_async_with_pipes (const gchar *working_directory, * implications, so consider using g_spawn_sync() directly if * appropriate. Possible errors are those from g_spawn_sync() and those * from g_shell_parse_argv(). + * + * If @exit_status is non-%NULL, the exit status of the child is stored there as + * it would be returned by waitpid(); standard UNIX macros such as WIFEXITED() + * and WEXITSTATUS() must be used to evaluate the exit status. * * On Windows, please note the implications of g_shell_parse_argv() * parsing @command_line. Space is a separator, and backslashes are