[Pkg-javascript-commits] [pdf.js] 112/139: Fixed empty packet parsing bug

David Prévot taffit at moszumanska.debian.org
Fri Jan 9 21:18:34 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository pdf.js.

commit 3d8b71175c3ce5564c7a16a3f128519189240ad1
Author: MaMazav <idanigra at hotmail.com>
Date:   Sat Dec 20 22:31:28 2014 +0200

    Fixed empty packet parsing bug
    
    Packet iterator was not advanced for empty packets.
---
 src/core/jpx.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/core/jpx.js b/src/core/jpx.js
index 6e1802e..17ee98d 100644
--- a/src/core/jpx.js
+++ b/src/core/jpx.js
@@ -1097,10 +1097,10 @@ var JpxImage = (function JpxImageClosure() {
         // Skip also marker segment length and packet sequence ID
         skipBytes(4);
       }
+      var packet = packetsIterator.nextPacket();
       if (!readBits(1)) {
         continue;
       }
-      var packet = packetsIterator.nextPacket();
       var layerNumber = packet.layerNumber;
       var queue = [], codeblock;
       for (var i = 0, ii = packet.codeblocks.length; i < ii; i++) {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git



More information about the Pkg-javascript-commits mailing list