Fix: get_subbuf: bound number of consumerd retry
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 5 Jan 2015 02:06:19 +0000 (21:06 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 5 Jan 2015 02:16:36 +0000 (21:16 -0500)
commit87edc3384d84e55d7dd736c71f1885ef7b735ad3
tree16b4fc41cb87b201e375b78a8334af385f4fa7b8
parentf5bd78ecfb58bcf70f67ce329484829e5a10ebd7
Fix: get_subbuf: bound number of consumerd retry

When an application traced with per-UID buffers vanishes between its
reserve and commit ring buffer operations (e.g. segfault), it may cause
the consumer daemon to enter an endless loop, awaiting for the
application to complete its commit.

Fix this situation by bounding the number of retry using an adaptative
approach: try actively for a few times, and then try a few more times
with a 10ms delay between attempts.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
libringbuffer/ring_buffer_frontend.c
This page took 0.02628 seconds and 4 git commands to generate.