aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/DecoderAPI.cxx4
1 files changed, 2 insertions, 2 deletions
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;
}