Check NULL pointer dereferencing from GetDirect

BUG=431770
R=tsepez@chromium.org

Review URL: https://codereview.chromium.org/728993002
diff --git a/xfa/src/fxfa/src/app/xfa_ffdoc.cpp b/xfa/src/fxfa/src/app/xfa_ffdoc.cpp
index 9c68603..625a34d 100644
--- a/xfa/src/fxfa/src/app/xfa_ffdoc.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffdoc.cpp
@@ -233,15 +233,11 @@
     if (pAcroForm == NULL) {

         return FALSE;

     }

-    CPDF_Object* pElementXFA = pAcroForm->GetElement(FX_BSTRC("XFA"));

+    CPDF_Object* pElementXFA = pAcroForm->GetElementValue(FX_BSTRC("XFA"));

     if (pElementXFA == NULL) {

         return FALSE;

     }

     FX_INT32 iObjType = pElementXFA->GetType();

-    if (iObjType == PDFOBJ_REFERENCE) {

-        pElementXFA = pElementXFA->GetDirect();

-        iObjType = pElementXFA->GetType();

-    }

     CFX_ArrayTemplate<CPDF_Stream*> xfaStreams;

     if (iObjType == PDFOBJ_ARRAY) {

         CPDF_Array* pXFAArray = (CPDF_Array*)pElementXFA;