From e076ff9085c517e9e3a6228080f2405637921f1c Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 8 Nov 2013 12:15:05 +0100 Subject: DecoderAPI: log without holding mutex --- src/DecoderAPI.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/DecoderAPI.cxx b/src/DecoderAPI.cxx index fbe4d98c0..87d104465 100644 --- a/src/DecoderAPI.cxx +++ b/src/DecoderAPI.cxx @@ -283,11 +283,11 @@ decoder_read(Decoder *decoder, assert(nbytes == 0 || !error.IsDefined()); assert(nbytes > 0 || error.IsDefined() || is.IsEOF()); + is.Unlock(); + if (gcc_unlikely(nbytes == 0 && error.IsDefined())) LogError(error); - is.Unlock(); - return nbytes; } -- cgit v1.2.3