mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-30 22:43:12 +03:00
Update.
2004-09-25 Jakub Jelinek <jakub@redhat.com> * sysdeps/unix/sysv/linux/i386/setuid.c (__setuid): Remove second result declaration. 2004-09-22 Andreas Schwab <schwab@suse.de> * sysdeps/unix/sysv/linux/ia64/sysdep.h: Adjust whitespace.
This commit is contained in:
@ -1,3 +1,12 @@
|
||||
2004-09-25 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
* sysdeps/unix/sysv/linux/i386/setuid.c (__setuid): Remove second
|
||||
result declaration.
|
||||
|
||||
2004-09-22 Andreas Schwab <schwab@suse.de>
|
||||
|
||||
* sysdeps/unix/sysv/linux/ia64/sysdep.h: Adjust whitespace.
|
||||
|
||||
2004-09-24 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* misc/daemon.c (daemon): Don't succeed if /dev/null cannot be
|
||||
|
@ -1,3 +1,11 @@
|
||||
2004-09-25 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* descr.h (struct pthread): Add stopped_start field.
|
||||
* sysdeps/pthread/createthread.c (create_thread): Set
|
||||
start_stopped flag in descriptor for new thread appropriately.
|
||||
* pthread_create.c (start_thread): Only take lock to be stopped on
|
||||
startup if stopped_start flag says so.
|
||||
|
||||
2004-09-24 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* pthread_create.c (__pthread_create_2_1): Remember whether thread
|
||||
|
@ -197,6 +197,9 @@ struct pthread
|
||||
/* True if the user provided the stack. */
|
||||
bool user_stack;
|
||||
|
||||
/* True if thread must stop at startup time. */
|
||||
bool stopped_start;
|
||||
|
||||
/* Lock to synchronize access to the descriptor. */
|
||||
lll_lock_t lock;
|
||||
|
||||
|
@ -252,14 +252,17 @@ start_thread (void *arg)
|
||||
/* Store the new cleanup handler info. */
|
||||
THREAD_SETMEM (pd, cleanup_jmp_buf, &unwind_buf);
|
||||
|
||||
int oldtype = CANCEL_ASYNC ();
|
||||
if (__builtin_expect (pd->stopped_start, 0))
|
||||
{
|
||||
int oldtype = CANCEL_ASYNC ();
|
||||
|
||||
/* Get the lock the parent locked to force synchronization. */
|
||||
lll_lock (pd->lock);
|
||||
/* And give it up right away. */
|
||||
lll_unlock (pd->lock);
|
||||
/* Get the lock the parent locked to force synchronization. */
|
||||
lll_lock (pd->lock);
|
||||
/* And give it up right away. */
|
||||
lll_unlock (pd->lock);
|
||||
|
||||
CANCEL_RESET (oldtype);
|
||||
CANCEL_RESET (oldtype);
|
||||
}
|
||||
|
||||
/* Run the code the user provided. */
|
||||
#ifdef CALL_THREAD_FCT
|
||||
|
@ -186,6 +186,9 @@ create_thread (struct pthread *pd, const struct pthread_attr *attr,
|
||||
if ((_mask & (__nptl_threads_events.event_bits[_idx]
|
||||
| pd->eventbuf.eventmask.event_bits[_idx])) != 0)
|
||||
{
|
||||
/* We always must have the thread start stopped. */
|
||||
pd->stopped_start = true;
|
||||
|
||||
/* Create the thread. We always create the thread stopped
|
||||
so that it does not get far before we tell the debugger. */
|
||||
int res = do_clone (pd, attr, clone_flags, start_thread,
|
||||
@ -224,10 +227,11 @@ create_thread (struct pthread *pd, const struct pthread_attr *attr,
|
||||
/* Determine whether the newly created threads has to be started
|
||||
stopped since we have to set the scheduling parameters or set the
|
||||
affinity. */
|
||||
int stopped = 0;
|
||||
bool stopped = false;
|
||||
if (attr != NULL && (attr->cpuset != NULL
|
||||
|| (attr->flags & ATTR_FLAG_NOTINHERITSCHED) != 0))
|
||||
stopped = 1;
|
||||
stopped = true;
|
||||
pd->stopped_start = stopped;
|
||||
|
||||
/* Actually create the thread. */
|
||||
int res = do_clone (pd, attr, clone_flags, start_thread,
|
||||
|
@ -47,7 +47,6 @@ __setuid (uid_t uid)
|
||||
# ifdef __NR_setuid32
|
||||
if (__libc_missing_32bit_uids <= 0)
|
||||
{
|
||||
int result;
|
||||
int saved_errno = errno;
|
||||
|
||||
result = INLINE_SYSCALL (setuid32, 1, uid);
|
||||
|
@ -165,7 +165,7 @@
|
||||
|
||||
#undef PSEUDO_ERRVAL
|
||||
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
||||
ENTRY(name) \
|
||||
ENTRY(name) \
|
||||
DO_CALL (SYS_ify(syscall_name)); \
|
||||
cmp.eq p6,p0=-1,r10; \
|
||||
(p6) mov r10=r8;
|
||||
@ -241,14 +241,14 @@
|
||||
DO_INLINE_SYSCALL_NCS (__NR_##name, nr, ##args)
|
||||
|
||||
#undef INLINE_SYSCALL
|
||||
#define INLINE_SYSCALL(name, nr, args...) \
|
||||
({ \
|
||||
DO_INLINE_SYSCALL_NCS(__NR_##name, nr, args)\
|
||||
if (_r10 == -1) \
|
||||
{ \
|
||||
__set_errno (_retval); \
|
||||
_retval = -1; \
|
||||
} \
|
||||
#define INLINE_SYSCALL(name, nr, args...) \
|
||||
({ \
|
||||
DO_INLINE_SYSCALL_NCS (__NR_##name, nr, args) \
|
||||
if (_r10 == -1) \
|
||||
{ \
|
||||
__set_errno (_retval); \
|
||||
_retval = -1; \
|
||||
} \
|
||||
_retval; })
|
||||
|
||||
#undef INTERNAL_SYSCALL_DECL
|
||||
@ -257,7 +257,7 @@
|
||||
#undef INTERNAL_SYSCALL
|
||||
#define INTERNAL_SYSCALL_NCS(name, err, nr, args...) \
|
||||
({ \
|
||||
DO_INLINE_SYSCALL_NCS(name, nr, args) \
|
||||
DO_INLINE_SYSCALL_NCS (name, nr, args) \
|
||||
err = _r10; \
|
||||
_retval; })
|
||||
#define INTERNAL_SYSCALL(name, err, nr, args...) \
|
||||
|
Reference in New Issue
Block a user