Mercurial > octave
changeset 22603:610f88ed2b78 stable
avoid gnulib waitpid replacement for Windows systems (bug #49211)
* wait-wrappers.c (octave_waitpid_wrapper): Always set status to 0 and
return -1 on Windows systems.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 06 Oct 2016 15:41:06 -0400 |
parents | 883b72cdf0b2 |
children | 66ac9dd3e675 177e0c71bcc0 |
files | liboctave/wrappers/wait-wrappers.c |
diffstat | 1 files changed, 7 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/liboctave/wrappers/wait-wrappers.c Thu Oct 06 01:08:22 2016 -0500 +++ b/liboctave/wrappers/wait-wrappers.c Thu Oct 06 15:41:06 2016 -0400 @@ -49,7 +49,14 @@ pid_t octave_waitpid_wrapper (pid_t pid, int *statusp, int options) { +#if defined (__WIN32__) && ! defined (__CYGWIN__) + // gnulib's waitpid replacement currently uses _cwait, which + // apparently only works with console applications. + *statusp = 0; + return -1; +#else return waitpid (pid, statusp, options); +#endif } int