Browse Source

PDF.js version 1.0.406

master v1.0.406
Yury Delendik 10 years ago
parent
commit
6f1146263d
  1. 2
      bower.json
  2. 22
      build/pdf.combined.js
  3. 4
      build/pdf.js
  4. 22
      build/pdf.worker.js
  5. 2
      package.json

2
bower.json

@ -1,6 +1,6 @@
{ {
"name": "pdfjs-dist", "name": "pdfjs-dist",
"version": "1.0.402", "version": "1.0.406",
"keywords": [ "keywords": [
"Mozilla", "Mozilla",
"pdf", "pdf",

22
build/pdf.combined.js

@ -21,8 +21,8 @@ if (typeof PDFJS === 'undefined') {
(typeof window !== 'undefined' ? window : this).PDFJS = {}; (typeof window !== 'undefined' ? window : this).PDFJS = {};
} }
PDFJS.version = '1.0.402'; PDFJS.version = '1.0.406';
PDFJS.build = 'b557b87'; PDFJS.build = 'c0a6b0f';
(function pdfjsWrapper() { (function pdfjsWrapper() {
// Use strict in our context only - users might not want it // Use strict in our context only - users might not want it
@ -9051,15 +9051,7 @@ var XRef = (function XRefClosure() {
error('bad XRef entry'); error('bad XRef entry');
} }
if (this.encrypt && !suppressEncryption) { if (this.encrypt && !suppressEncryption) {
try { xrefEntry = parser.getObj(this.encrypt.createCipherTransform(num, gen));
xrefEntry = parser.getObj(this.encrypt.createCipherTransform(num,
gen));
} catch (ex) {
// Almost all streams must be encrypted, but sometimes
// they are not, probably due to some broken generators.
// Retrying without encryption...
return this.fetch(ref, true);
}
} else { } else {
xrefEntry = parser.getObj(); xrefEntry = parser.getObj();
} }
@ -40556,6 +40548,7 @@ var Parser = (function ParserClosure() {
if (stream.dict.get('Length') === 0) { if (stream.dict.get('Length') === 0) {
return new NullStream(stream); return new NullStream(stream);
} }
try {
var xrefStreamStats = this.xref.stats.streamTypes; var xrefStreamStats = this.xref.stats.streamTypes;
if (name == 'FlateDecode' || name == 'Fl') { if (name == 'FlateDecode' || name == 'Fl') {
xrefStreamStats[StreamType.FLATE] = true; xrefStreamStats[StreamType.FLATE] = true;
@ -40608,6 +40601,13 @@ var Parser = (function ParserClosure() {
} }
warn('filter "' + name + '" not supported yet'); warn('filter "' + name + '" not supported yet');
return stream; return stream;
} catch (ex) {
if (ex instanceof MissingDataException) {
throw ex;
}
warn('Invalid stream: \"' + ex + '\"');
return new NullStream(stream);
}
} }
}; };

4
build/pdf.js

@ -21,8 +21,8 @@ if (typeof PDFJS === 'undefined') {
(typeof window !== 'undefined' ? window : this).PDFJS = {}; (typeof window !== 'undefined' ? window : this).PDFJS = {};
} }
PDFJS.version = '1.0.402'; PDFJS.version = '1.0.406';
PDFJS.build = 'b557b87'; PDFJS.build = 'c0a6b0f';
(function pdfjsWrapper() { (function pdfjsWrapper() {
// Use strict in our context only - users might not want it // Use strict in our context only - users might not want it

22
build/pdf.worker.js vendored

@ -21,8 +21,8 @@ if (typeof PDFJS === 'undefined') {
(typeof window !== 'undefined' ? window : this).PDFJS = {}; (typeof window !== 'undefined' ? window : this).PDFJS = {};
} }
PDFJS.version = '1.0.402'; PDFJS.version = '1.0.406';
PDFJS.build = 'b557b87'; PDFJS.build = 'c0a6b0f';
(function pdfjsWrapper() { (function pdfjsWrapper() {
// Use strict in our context only - users might not want it // Use strict in our context only - users might not want it
@ -4215,15 +4215,7 @@ var XRef = (function XRefClosure() {
error('bad XRef entry'); error('bad XRef entry');
} }
if (this.encrypt && !suppressEncryption) { if (this.encrypt && !suppressEncryption) {
try { xrefEntry = parser.getObj(this.encrypt.createCipherTransform(num, gen));
xrefEntry = parser.getObj(this.encrypt.createCipherTransform(num,
gen));
} catch (ex) {
// Almost all streams must be encrypted, but sometimes
// they are not, probably due to some broken generators.
// Retrying without encryption...
return this.fetch(ref, true);
}
} else { } else {
xrefEntry = parser.getObj(); xrefEntry = parser.getObj();
} }
@ -35720,6 +35712,7 @@ var Parser = (function ParserClosure() {
if (stream.dict.get('Length') === 0) { if (stream.dict.get('Length') === 0) {
return new NullStream(stream); return new NullStream(stream);
} }
try {
var xrefStreamStats = this.xref.stats.streamTypes; var xrefStreamStats = this.xref.stats.streamTypes;
if (name == 'FlateDecode' || name == 'Fl') { if (name == 'FlateDecode' || name == 'Fl') {
xrefStreamStats[StreamType.FLATE] = true; xrefStreamStats[StreamType.FLATE] = true;
@ -35772,6 +35765,13 @@ var Parser = (function ParserClosure() {
} }
warn('filter "' + name + '" not supported yet'); warn('filter "' + name + '" not supported yet');
return stream; return stream;
} catch (ex) {
if (ex instanceof MissingDataException) {
throw ex;
}
warn('Invalid stream: \"' + ex + '\"');
return new NullStream(stream);
}
} }
}; };

2
package.json

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

Loading…
Cancel
Save