Update CloseDocument and ExitForm
authorxiaoxia_yu <xiaoxia_yu@foxitsoftware.com>
Thu, 30 Oct 2014 02:36:45 +0000 (10:36 +0800)
committerBo Xu <bo_xu@foxitsoftware.com>
Mon, 3 Nov 2014 19:10:20 +0000 (11:10 -0800)
samples/pdfium_test.cc

index a9904ab..c5ac75e 100644 (file)
@@ -356,8 +356,8 @@ void RenderPdf(const char* name, const char* pBuf, size_t len,
   }
 
   FORM_DoDocumentAAction(form, FPDFDOC_AACTION_WC);
-  FPDFDOC_ExitFormFillEnviroument(form);
   FPDF_CloseDocument(doc);
+  FPDFDOC_ExitFormFillEnviroument(form);
   FPDFAvail_Destroy(pdf_avail);
 
   printf("Loaded, parsed and rendered %zu pages.\n", rendered_pages);