mirror of
https://sourceware.org/git/glibc.git
synced 2025-08-07 06:43:00 +03:00
* inet/bug-if1.c: Include <string.h>.
2004-06-19 Roland McGrath <roland@redhat.com> * sysdeps/posix/waitid.c (do_waitid) [DO_WAITID]: Define function under this macro name instead. [NO_DO_WAITID]: Don't define it at all. (do_waitid) [WNOWAIT, WEXITED]: If these POSIX.1 waitid flag bits are defined, then return ENOTSUP for combinations of selection bits other than WEXITED and WEXITED|WSTOPPED, which this version cannot support. * posix/tst-waitid.c: New file. * posix/Makefile (tests): Add it. 2004-06-28 Jakub Jelinek <jakub@redhat.com>
This commit is contained in:
16
ChangeLog
16
ChangeLog
@@ -1,3 +1,19 @@
|
|||||||
|
2004-06-28 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
* inet/bug-if1.c: Include <string.h>.
|
||||||
|
|
||||||
|
2004-06-19 Roland McGrath <roland@redhat.com>
|
||||||
|
|
||||||
|
* sysdeps/posix/waitid.c (do_waitid) [DO_WAITID]: Define function
|
||||||
|
under this macro name instead.
|
||||||
|
[NO_DO_WAITID]: Don't define it at all.
|
||||||
|
(do_waitid) [WNOWAIT, WEXITED]: If these POSIX.1 waitid flag bits are
|
||||||
|
defined, then return ENOTSUP for combinations of selection bits other
|
||||||
|
than WEXITED and WEXITED|WSTOPPED, which this version cannot support.
|
||||||
|
|
||||||
|
* posix/tst-waitid.c: New file.
|
||||||
|
* posix/Makefile (tests): Add it.
|
||||||
|
|
||||||
2004-06-28 Jakub Jelinek <jakub@redhat.com>
|
2004-06-28 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
* sysdeps/unix/alpha/sysdep.h (inline_syscall6): Fix a typo.
|
* sysdeps/unix/alpha/sysdep.h (inline_syscall6): Fix a typo.
|
||||||
|
@@ -20,6 +20,7 @@
|
|||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <limits.h>
|
#include <limits.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <string.h>
|
||||||
#include <net/if.h>
|
#include <net/if.h>
|
||||||
|
|
||||||
|
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
/* Pseudo implementation of waitid.
|
/* Pseudo implementation of waitid.
|
||||||
Copyright (C) 1997, 1998, 2002, 2003 Free Software Foundation, Inc.
|
Copyright (C) 1997, 1998, 2002, 2003, 2004 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
Contributed by Zack Weinberg <zack@rabi.phys.columbia.edu>, 1997.
|
Contributed by Zack Weinberg <zack@rabi.phys.columbia.edu>, 1997.
|
||||||
|
|
||||||
@@ -28,8 +28,15 @@
|
|||||||
#include <sysdep-cancel.h>
|
#include <sysdep-cancel.h>
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef DO_WAITID
|
||||||
|
# define OUR_WAITID DO_WAITID
|
||||||
|
#elif !defined NO_DO_WAITID
|
||||||
|
# define OUR_WAITID do_waitid
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef OUR_WAITID
|
||||||
static int
|
static int
|
||||||
do_waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options)
|
OUR_WAITID (idtype_t idtype, id_t id, siginfo_t *infop, int options)
|
||||||
{
|
{
|
||||||
pid_t pid, child;
|
pid_t pid, child;
|
||||||
int status;
|
int status;
|
||||||
@@ -66,6 +73,22 @@ do_waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* This emulation using waitpid cannot support the waitid modes in which
|
||||||
|
we do not reap the child, or match only stopped and not dead children. */
|
||||||
|
if (0
|
||||||
|
#ifdef WNOWAIT
|
||||||
|
|| (options & WNOWAIT)
|
||||||
|
#endif
|
||||||
|
#ifdef WEXITED
|
||||||
|
|| ((options & (WEXITED|WSTOPPED|WCONTINUED))
|
||||||
|
!= (WEXITED | (options & WUNTRACED)))
|
||||||
|
#endif
|
||||||
|
)
|
||||||
|
{
|
||||||
|
__set_errno (ENOTSUP);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
/* Note the waitid() is a cancellation point. But since we call
|
/* Note the waitid() is a cancellation point. But since we call
|
||||||
waitpid() which itself is a cancellation point we do not have
|
waitpid() which itself is a cancellation point we do not have
|
||||||
to do anything here. */
|
to do anything here. */
|
||||||
@@ -118,6 +141,7 @@ do_waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
|
Reference in New Issue
Block a user