summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pdf/out_of_process_instance.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/pdf/out_of_process_instance.cc b/pdf/out_of_process_instance.cc
index d8188ad..265c53f 100644
--- a/pdf/out_of_process_instance.cc
+++ b/pdf/out_of_process_instance.cc
@@ -295,6 +295,9 @@ OutOfProcessInstance::OutOfProcessInstance(PP_Instance instance)
OutOfProcessInstance::~OutOfProcessInstance() {
RemovePerInstanceObject(kPPPPdfInterface, this);
+ // Explicitly reset the PDFEngine during destruction as it may call back into
+ // this object.
+ engine_.reset();
}
bool OutOfProcessInstance::Init(uint32_t argc,