mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-20 15:18:08 +02:00
Tried to add a destroy function to free memeory, but doesn't seem to help
This commit is contained in:
parent
20d8a13c9e
commit
921f8bd669
2 changed files with 24 additions and 1 deletions
|
@ -50,6 +50,11 @@ function load() {
|
|||
window.onload = load;
|
||||
|
||||
function nextTask() {
|
||||
// If there is a pdfDoc on the last task executed, destroy it to free memory.
|
||||
if (task && task.pdfDoc) {
|
||||
task.pdfDoc.destroy();
|
||||
delete task.pdfDoc;
|
||||
}
|
||||
if (currentTaskIdx == manifest.length) {
|
||||
return done();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue