Merge pull request #8184 from Rob--W/rethrow-missing-data-if-needed

Rethrow MissingDataException when needed
This commit is contained in:
Jonas Jenwald 2017-03-22 18:21:21 +01:00 committed by GitHub
commit 02370f952a
2 changed files with 6 additions and 0 deletions

View File

@ -467,6 +467,9 @@ var PDFDocument = (function PDFDocumentClosure() {
}
}
} catch (ex) {
if (ex instanceof MissingDataException) {
throw ex;
}
info('Something wrong with AcroForm entry');
this.acroForm = null;
}

View File

@ -104,6 +104,9 @@ var Catalog = (function CatalogClosure() {
try {
metadata = stringToUTF8String(bytesToString(stream.getBytes()));
} catch (e) {
if (e instanceof MissingDataException) {
throw e;
}
info('Skipping invalid metadata.');
}
}