Re: [PATCH] client: clarify wl_display_prepare_read() semantics

2014-09-04 Thread Bill Spitzak
On 08/28/2014 08:52 AM, Pekka Paalanen wrote: The manual I could find: http://pubs.opengroup.org/onlinepubs/7908799/xsh/pthread_cond_wait.html says that spurious wakeups may occur. So better keep the serial there. Yes indeed. I believe it is valid, and even common, for pthread_cond_wait to

Re: [PATCH] client: clarify wl_display_prepare_read() semantics

2014-08-28 Thread Pekka Paalanen
On Mon, 4 Aug 2014 11:30:46 +0200 Marek Chalupa mchqwe...@gmail.com wrote: From the doc comment I get the feeling, that after successfull call to wl_display_prepare_read(), the thread gains exclusive access to the fd. That is not true. It only ensures that _one_ of the threads, that called

Re: [PATCH] client: clarify wl_display_prepare_read() semantics

2014-08-28 Thread Marek Chalupa
On 28 August 2014 12:02, Pekka Paalanen ppaala...@gmail.com wrote: On Mon, 4 Aug 2014 11:30:46 +0200 Marek Chalupa mchqwe...@gmail.com wrote: From the doc comment I get the feeling, that after successfull call to wl_display_prepare_read(), the thread gains exclusive access to the fd.

Re: [PATCH] client: clarify wl_display_prepare_read() semantics

2014-08-28 Thread Pekka Paalanen
On Thu, 28 Aug 2014 15:59:37 +0200 Marek Chalupa mchqwe...@gmail.com wrote: On 28 August 2014 12:02, Pekka Paalanen ppaala...@gmail.com wrote: On Mon, 4 Aug 2014 11:30:46 +0200 Marek Chalupa mchqwe...@gmail.com wrote: From the doc comment I get the feeling, that after successfull

Re: [PATCH] client: clarify wl_display_prepare_read() semantics

2014-08-28 Thread Marek Chalupa
On 28 August 2014 17:52, Pekka Paalanen ppaala...@gmail.com wrote: On Thu, 28 Aug 2014 15:59:37 +0200 Marek Chalupa mchqwe...@gmail.com wrote: On 28 August 2014 12:02, Pekka Paalanen ppaala...@gmail.com wrote: On Mon, 4 Aug 2014 11:30:46 +0200 Marek Chalupa mchqwe...@gmail.com

[PATCH] client: clarify wl_display_prepare_read() semantics

2014-08-04 Thread Marek Chalupa
From the doc comment I get the feeling, that after successfull call to wl_display_prepare_read(), the thread gains exclusive access to the fd. That is not true. It only ensures that _one_ of the threads, that called this function, will read from the fd and there will be no race. Here's slice of