• select(0, …) misbehaves on Interix (by Markus Duft <mduft@gentoo.org>)

• select(n, NULL, NULL, NULL, …) behaves the same (by Bruno Haible)
This commit is contained in:
tg 2011-11-09 22:17:26 +00:00
parent f048ac2f58
commit 90afc54ee8
3 changed files with 6 additions and 6 deletions

View File

@ -1,4 +1,4 @@
# $MirOS: src/bin/mksh/check.t,v 1.488 2011/11/08 23:10:58 tg Exp $ # $MirOS: src/bin/mksh/check.t,v 1.489 2011/11/09 22:17:23 tg Exp $
# $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $ # $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $
# $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $ # $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $
# $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $ # $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $
@ -25,7 +25,7 @@
# http://www.research.att.com/~gsf/public/ifs.sh # http://www.research.att.com/~gsf/public/ifs.sh
expected-stdout: expected-stdout:
@(#)MIRBSD KSH R40 2011/11/07 @(#)MIRBSD KSH R40 2011/11/09
description: description:
Check version of shell. Check version of shell.
stdin: stdin:

View File

@ -38,7 +38,7 @@
#endif #endif
#endif #endif
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.197 2011/09/07 15:24:15 tg Exp $"); __RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.198 2011/11/09 22:17:25 tg Exp $");
#if HAVE_KILLPG #if HAVE_KILLPG
/* /*
@ -3646,7 +3646,7 @@ c_sleep(const char **wp)
/* block SIGCHLD from interrupting us, though */ /* block SIGCHLD from interrupting us, though */
sigprocmask(SIG_BLOCK, &sm_sigchld, &omask); sigprocmask(SIG_BLOCK, &sm_sigchld, &omask);
#endif #endif
if (select(0, NULL, NULL, NULL, &tv) == 0 || errno == EINTR) if (select(1, NULL, NULL, NULL, &tv) == 0 || errno == EINTR)
/* /*
* strictly speaking only for SIGALRM, but the * strictly speaking only for SIGALRM, but the
* execution may be interrupted by other signals * execution may be interrupted by other signals

4
sh.h
View File

@ -151,9 +151,9 @@
#endif #endif
#ifdef EXTERN #ifdef EXTERN
__RCSID("$MirOS: src/bin/mksh/sh.h,v 1.500 2011/11/08 22:07:14 tg Exp $"); __RCSID("$MirOS: src/bin/mksh/sh.h,v 1.501 2011/11/09 22:17:26 tg Exp $");
#endif #endif
#define MKSH_VERSION "R40 2011/11/07" #define MKSH_VERSION "R40 2011/11/09"
#ifndef MKSH_INCLUDES_ONLY #ifndef MKSH_INCLUDES_ONLY