[gs-commits] mupdf 1.16.1.34 Unlock curl stream both along normal and

[email protected] (Sebastian Rasmussen)
Newsgroups gmane.comp.printing.ghostscript.cvs
Message-ID <[email protected]>
commit 898502c2186ed7b45eb01facdaf159078b66d1e3
Author: Sebastian Rasmussen <[email protected]>
Date:   Thu Sep 5 22:49:54 2019 +0200

    Unlock curl stream both along normal and error path.

diff --git a/platform/x11/curl_stream.c b/platform/x11/curl_stream.c
index 7f88b04..4c1f699 100644
--- a/platform/x11/curl_stream.c
+++ b/platform/x11/curl_stream.c
@@ -363,11 +363,9 @@ static int cs_next(fz_context *ctx, fz_stream *stream, size_t len)
 
 	if (read_point > state->content_length)
 	{
+		unlock(state);
 		if (state->data_arrived == 0)
-		{
-			unlock(state);
 			fz_throw(ctx, FZ_ERROR_TRYLATER, "read of a block we don't have (A) (offset=%ld)", read_point);
-		}
 		return EOF;
 	}
 

http://git.ghostscript.com/?p=mupdf.git;a=commit;h=898502c2186ed7b45eb01facdaf159078b66d1e3

--
MuPDF library
Artifex Software, Inc.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.