]> git.ipfire.org Git - thirdparty/tor.git/commit
Fix possible infinite loop on pipe/sock_drain()
authorDavid Goulet <dgoulet@ev0ke.net>
Fri, 30 Jan 2015 19:59:48 +0000 (14:59 -0500)
committerDavid Goulet <dgoulet@ev0ke.net>
Fri, 30 Jan 2015 20:05:18 +0000 (15:05 -0500)
commit51f793e37e55b29700f76ca9cdb3199e636bb51d
treee8d628a7662d51a41258a5215035f0dd5c26873f
parent44e9dafb67370aa6fb163cda150a80466f668111
Fix possible infinite loop on pipe/sock_drain()

If the returned value of read/recv is 0 (meaning EOF), we'll end up in an
infinite loop (active wait) until something is written on the pipe which is
not really what we want here especially because those functions are called
from the main thread.

Signed-off-by: David Goulet <dgoulet@ev0ke.net>
changes/bug14554 [new file with mode: 0644]
src/common/compat_threads.c