Tom Sepez 13dfdd4b33 Dismiss exceptions while setting properties/elements from JS handlers.
Otherwise, we can't use any other V8 functionality until the
exception is handled.

Bug: chromium:1098213
Change-Id: Ie846194afab52e5d61795c7af74b1e29b46db953
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/70913
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
2020-06-25 22:03:50 +00:00

66 lines
905 B
Plaintext

{{header}}
{{object 1 0}} <<
/Type /Catalog
/Pages 2 0 R
/OpenAction 8 0 R
>>
endobj
{{object 2 0}} <<
/Type /Pages
/Count 2
/Kids [
3 0 R
4 0 R
]
>>
endobj
{{object 3 0}} <<
/Type /Page
/Parent 2 0 R
/CropBox [179 173 200 75]
>>
endobj
{{object 4 0}} <<
/Type /Page
/Parent 2 0 R
/CropBox [127 214 186 29]
/Annots [
5 0 R
6 0 R
7 0 R
]
>>
endobj
{{object 5 0}} <<
/Type /Annot
>
endobj
{{object 6 0}} <<
/Type /Annot
>>
endobj
{{object 7 0}} <<
/Type /Annot
>>
endobj
{{object 8 0}} <<
/Type /Action
/S /JavaScript
/JS (
Object.defineProperty(Array.prototype, 1, {
set: (v) => {
Object.defineProperty(Array.prototype, 1, {
get: () => {}
});
}
});
try { this.getAnnots(); } catch (e) { app.alert('Caught: ' + e); }
app.alert('Done');
)
>>
endobj
{{xref}}
{{trailer}}
{{startxref}}
%%EOF