mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-29 11:41:21 +03:00
Update.
2003-04-03 Jakub Jelinek <jakub@redhat.com> * pthread.c (pthread_initialize): Unblock __pthread_sig_cancel in case the parent blocked it.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
2003-04-03 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
* pthread.c (pthread_initialize): Unblock __pthread_sig_cancel
|
||||||
|
in case the parent blocked it.
|
||||||
|
|
||||||
2003-04-02 Jakub Jelinek <jakub@redhat.com>
|
2003-04-02 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
* Makefile (libpthread-routines): Add pthread_atfork.
|
* Makefile (libpthread-routines): Add pthread_atfork.
|
||||||
|
@ -529,6 +529,10 @@ static void pthread_initialize(void)
|
|||||||
sigemptyset(&mask);
|
sigemptyset(&mask);
|
||||||
sigaddset(&mask, __pthread_sig_restart);
|
sigaddset(&mask, __pthread_sig_restart);
|
||||||
sigprocmask(SIG_BLOCK, &mask, NULL);
|
sigprocmask(SIG_BLOCK, &mask, NULL);
|
||||||
|
/* And unblock __pthread_sig_cancel if it has been blocked. */
|
||||||
|
sigdelset(&mask, __pthread_sig_restart);
|
||||||
|
sigaddset(&mask, __pthread_sig_cancel);
|
||||||
|
sigprocmask(SIG_UNBLOCK, &mask, NULL);
|
||||||
/* Register an exit function to kill all other threads. */
|
/* Register an exit function to kill all other threads. */
|
||||||
/* Do it early so that user-registered atexit functions are called
|
/* Do it early so that user-registered atexit functions are called
|
||||||
before pthread_*exit_process. */
|
before pthread_*exit_process. */
|
||||||
|
@ -85,7 +85,7 @@ get_proc_path (char *buffer, size_t bufsize)
|
|||||||
|
|
||||||
/* Now store the copied value. But do it atomically. */
|
/* Now store the copied value. But do it atomically. */
|
||||||
assert (sizeof (long int) == sizeof (void *__unbounded));
|
assert (sizeof (long int) == sizeof (void *__unbounded));
|
||||||
if (! atomic_compare_and_exchange_bool_acq (&mount_proc, copy_result, NULL))
|
if (atomic_compare_and_exchange_bool_acq (&mount_proc, copy_result, NULL))
|
||||||
/* Replacing the value failed. This means another thread was
|
/* Replacing the value failed. This means another thread was
|
||||||
faster and we don't need the copy anymore. */
|
faster and we don't need the copy anymore. */
|
||||||
free (copy_result);
|
free (copy_result);
|
||||||
|
Reference in New Issue
Block a user