poppler/JBIG2Stream.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 40cc2ecfb925ba308f72b25c693ba98d58806ff2 Author: Albert Astals Cid <[email protected]> Date: Tue Jun 20 23:43:23 2017 +0200 Fix crash on broken documents Fixes bug #101524 diff --git a/poppler/JBIG2Stream.cc b/poppler/JBIG2Stream.cc index d26ba02b..067fb7f0 100644 --- a/poppler/JBIG2Stream.cc +++ b/poppler/JBIG2Stream.cc @@ -15,7 +15,7 @@ // // Copyright (C) 2006 Raj Kumar <[email protected]> // Copyright (C) 2006 Paul Walmsley <[email protected]> -// Copyright (C) 2006-2010, 2012, 2014-2016 Albert Astals Cid <[email protected]> +// Copyright (C) 2006-2010, 2012, 2014-2017 Albert Astals Cid <[email protected]> // Copyright (C) 2009 David Benjamin <[email protected]> // Copyright (C) 2011 Edward Jiang <[email protected]> // Copyright (C) 2012 William Bader <[email protected]> @@ -1304,7 +1304,7 @@ Goffset JBIG2Stream::getPos() { int JBIG2Stream::getChars(int nChars, Guchar *buffer) { int n, i; - if (nChars <= 0) { + if (nChars <= 0 || !dataPtr) { return 0; } if (dataEnd - dataPtr < nChars) { _______________________________________________ poppler mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/poppler
