This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [libc-alpha] mt-application hanging in exit()


Hi,

Kaz Kylheku wrote:
> 
> On Sat, 19 Jan 2002, Bertold Kolics wrote:
> 
> > I may have found the problem, but I still believe that there is a problem in glibc.
> 
> Nope, false alarm! Phew!
> 
> > Before setting up the signal handlers, I used to clear the signal mask of the process.
> 
> You should be aware that sigprocmask is restricted to use in a
> single-threaded process. From Draft 7 POSIX, (June 14, 2001):
> 
>         The use of the sigprocmask() function is unspecified
>         in a multi-threaded process.
> 
> Everyone who cares about writing code that can be compiled and linked
> with a MT application should use pthread_sigmask. It will do the
> same job as sigprocmask in a single-threaded process.
> 

Just one more comment on this (and that is why I think it should be clearly
indicated in the documentation of glibc that use of pthread_sigmask is
mandatory on Linux): UNIX International compliant systems make sigprocmask()
equivalent to pthread_sigmask(). glibc works differently - that's OK, but this
needs to be documented.

Once again, thanks to all who looked into this problem.

Regards,
Bertold


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]