This is the mail archive of the libc-alpha@sourceware.org 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: Update on freeze status of glibc 2.18?


> pthread_mutex_t foo = PTHREAD_MUTEX_INITIALIZER;
> 
> or 
> 
> pthread_mutex_t foo;
> pthread_mutex_init(&foo, NULL);

Precisely what POSIX specifies is that these are exactly equivalent to:

	pthread_mutex_t mutex;
	pthread_mutexattr_t attr;
	pthread_mutexattr_init (&attr);
	pthread_mutexattr_settype (&attr, PTHREAD_MUTEX_DEFAULT);
	pthread_mutex_init (&mutex, &attr);


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