[Bro-Dev] [Bro-Commits] [git/bro] master: Fix for input readers occasionally dead-locking. (c980d10)

Robin Sommer robin at icir.org
Fri Oct 25 11:24:21 PDT 2013


On Fri, Oct 25, 2013 at 00:04 -0400, you wrote:

>  * Since we know that read_ctr is only incremented after a successful
>  read, and write_ctr is only incremented after a successful write, the
>  two values should be equal iff the queue is empty.

That's actually not the case, and that was the problem. There can be
elements in the queue even if both pointers align; that happens if the
writer is exactly a full round ahead of the reader.

Robin

-- 
Robin Sommer * Phone +1 (510) 722-6541 *     robin at icir.org
ICSI/LBNL    * Fax   +1 (510) 666-2956 * www.icir.org/robin


More information about the bro-dev mailing list