Browse Source

PDF.js version 1.1.209

Pdf Bot 10 years ago
parent
commit
58162765d1
5 changed files with 16 additions and 10 deletions
  1. 1 1
      bower.json
  2. 6 3
      build/pdf.combined.js
  3. 2 2
      build/pdf.js
  4. 6 3
      build/pdf.worker.js
  5. 1 1
      package.json

+ 1 - 1
bower.json

@@ -1,6 +1,6 @@
 {
   "name": "pdfjs-dist",
-  "version": "1.1.207",
+  "version": "1.1.209",
   "main": [
     "build/pdf.js",
     "build/pdf.worker.js"

+ 6 - 3
build/pdf.combined.js

@@ -22,8 +22,8 @@ if (typeof PDFJS === 'undefined') {
   (typeof window !== 'undefined' ? window : this).PDFJS = {};
 }
 
-PDFJS.version = '1.1.207';
-PDFJS.build = 'c8fd9c8';
+PDFJS.version = '1.1.209';
+PDFJS.build = 'd7e6490';
 
 (function pdfjsWrapper() {
   // Use strict in our context only - users might not want it
@@ -12151,7 +12151,10 @@ var PDFFunction = (function PDFFunctionClosure() {
         var rmin = encode[2 * i];
         var rmax = encode[2 * i + 1];
 
-        tmpBuf[0] = rmin + (v - dmin) * (rmax - rmin) / (dmax - dmin);
+        // Prevent the value from becoming NaN as a result
+        // of division by zero (fixes issue6113.pdf).
+        tmpBuf[0] = dmin === dmax ? rmin :
+                    rmin + (v - dmin) * (rmax - rmin) / (dmax - dmin);
 
         // call the appropriate function
         fns[i](tmpBuf, 0, dest, destOffset);

+ 2 - 2
build/pdf.js

@@ -22,8 +22,8 @@ if (typeof PDFJS === 'undefined') {
   (typeof window !== 'undefined' ? window : this).PDFJS = {};
 }
 
-PDFJS.version = '1.1.207';
-PDFJS.build = 'c8fd9c8';
+PDFJS.version = '1.1.209';
+PDFJS.build = 'd7e6490';
 
 (function pdfjsWrapper() {
   // Use strict in our context only - users might not want it

+ 6 - 3
build/pdf.worker.js

@@ -22,8 +22,8 @@ if (typeof PDFJS === 'undefined') {
   (typeof window !== 'undefined' ? window : this).PDFJS = {};
 }
 
-PDFJS.version = '1.1.207';
-PDFJS.build = 'c8fd9c8';
+PDFJS.version = '1.1.209';
+PDFJS.build = 'd7e6490';
 
 (function pdfjsWrapper() {
   // Use strict in our context only - users might not want it
@@ -5798,7 +5798,10 @@ var PDFFunction = (function PDFFunctionClosure() {
         var rmin = encode[2 * i];
         var rmax = encode[2 * i + 1];
 
-        tmpBuf[0] = rmin + (v - dmin) * (rmax - rmin) / (dmax - dmin);
+        // Prevent the value from becoming NaN as a result
+        // of division by zero (fixes issue6113.pdf).
+        tmpBuf[0] = dmin === dmax ? rmin :
+                    rmin + (v - dmin) * (rmax - rmin) / (dmax - dmin);
 
         // call the appropriate function
         fns[i](tmpBuf, 0, dest, destOffset);

+ 1 - 1
package.json

@@ -1,6 +1,6 @@
 {
   "name": "pdfjs-dist",
-  "version": "1.1.207",
+  "version": "1.1.209",
   "description": "Generic build of Mozilla's PDF.js library.",
   "keywords": [
     "Mozilla",