Merge pull request #12988 from Snuffleupagus/rm-unneeded-MissingDataException
Remove unneeded `instanceof MissingDataException` checks
This commit is contained in:
commit
4b639d5d44
@ -64,7 +64,6 @@ import {
|
|||||||
WinAnsiEncoding,
|
WinAnsiEncoding,
|
||||||
ZapfDingbatsEncoding,
|
ZapfDingbatsEncoding,
|
||||||
} from "./encodings.js";
|
} from "./encodings.js";
|
||||||
import { getLookupTableFactory, MissingDataException } from "./core_utils.js";
|
|
||||||
import {
|
import {
|
||||||
getNormalizedUnicodes,
|
getNormalizedUnicodes,
|
||||||
getUnicodeForGlyph,
|
getUnicodeForGlyph,
|
||||||
@ -87,6 +86,7 @@ import {
|
|||||||
import { bidi } from "./bidi.js";
|
import { bidi } from "./bidi.js";
|
||||||
import { ColorSpace } from "./colorspace.js";
|
import { ColorSpace } from "./colorspace.js";
|
||||||
import { getGlyphsUnicode } from "./glyphlist.js";
|
import { getGlyphsUnicode } from "./glyphlist.js";
|
||||||
|
import { getLookupTableFactory } from "./core_utils.js";
|
||||||
import { getMetrics } from "./metrics.js";
|
import { getMetrics } from "./metrics.js";
|
||||||
import { MurmurHash3_64 } from "./murmurhash3.js";
|
import { MurmurHash3_64 } from "./murmurhash3.js";
|
||||||
import { OperatorList } from "./operator_list.js";
|
import { OperatorList } from "./operator_list.js";
|
||||||
@ -267,9 +267,6 @@ class PartialEvaluator {
|
|||||||
try {
|
try {
|
||||||
graphicState = xref.fetch(graphicState);
|
graphicState = xref.fetch(graphicState);
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
if (ex instanceof MissingDataException) {
|
|
||||||
throw ex;
|
|
||||||
}
|
|
||||||
// Avoid parsing a corrupt ExtGState more than once.
|
// Avoid parsing a corrupt ExtGState more than once.
|
||||||
processed.put(graphicState);
|
processed.put(graphicState);
|
||||||
|
|
||||||
@ -316,9 +313,6 @@ class PartialEvaluator {
|
|||||||
try {
|
try {
|
||||||
xObject = xref.fetch(xObject);
|
xObject = xref.fetch(xObject);
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
if (ex instanceof MissingDataException) {
|
|
||||||
throw ex;
|
|
||||||
}
|
|
||||||
// Avoid parsing a corrupt XObject more than once.
|
// Avoid parsing a corrupt XObject more than once.
|
||||||
processed.put(xObject);
|
processed.put(xObject);
|
||||||
|
|
||||||
@ -1270,9 +1264,6 @@ class PartialEvaluator {
|
|||||||
operatorList.addOp(fn, tilingPatternIR);
|
operatorList.addOp(fn, tilingPatternIR);
|
||||||
return undefined;
|
return undefined;
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
if (ex instanceof MissingDataException) {
|
|
||||||
throw ex;
|
|
||||||
}
|
|
||||||
// Handle any errors during normal TilingPattern parsing.
|
// Handle any errors during normal TilingPattern parsing.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1910,9 +1910,6 @@ var XRef = (function XRefClosure() {
|
|||||||
}
|
}
|
||||||
// The top-level /Pages dictionary isn't obviously corrupt.
|
// The top-level /Pages dictionary isn't obviously corrupt.
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
if (ex instanceof MissingDataException) {
|
|
||||||
throw ex;
|
|
||||||
}
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// taking the first one with 'ID'
|
// taking the first one with 'ID'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user