]> git.parisson.com Git - pdf.js.git/commitdiff
replacing non-existent page content with empty one
authornotmasteryet <async.processingjs@yahoo.com>
Tue, 10 Jan 2012 02:08:22 +0000 (20:08 -0600)
committernotmasteryet <async.processingjs@yahoo.com>
Tue, 10 Jan 2012 02:08:22 +0000 (20:08 -0600)
src/core.js

index 765a239b740b0a9d9eee3a45d316c9a2f6f5bb53..a9c5b15a2cb0c0206dafac10ac46274ed80ce3b7 100644 (file)
@@ -196,6 +196,9 @@ var Page = (function PageClosure() {
         for (i = 0; i < n; ++i)
           content[i] = xref.fetchIfRef(content[i]);
         content = new StreamsSequenceStream(content);
+      } else if (!content) {
+        // replacing non-existent page content with empty one
+        content = new Stream(new Uint8Array(0));
       }
 
       var pe = this.pe = new PartialEvaluator(