Index: fpdfsdk/javascript/PublicMethods.cpp |
diff --git a/fpdfsdk/javascript/PublicMethods.cpp b/fpdfsdk/javascript/PublicMethods.cpp |
index 3e2bc06f238ad90ed7d538515d1ec02830178c31..64b53fbf58ff862d8d2068a522222a02728a157c 100644 |
--- a/fpdfsdk/javascript/PublicMethods.cpp |
+++ b/fpdfsdk/javascript/PublicMethods.cpp |
@@ -1660,7 +1660,7 @@ FX_BOOL CJS_PublicMethods::AFSimple_Calculate( |
CJS_Context* pContext = static_cast<CJS_Context*>(cc); |
CJS_Runtime* pRuntime = CJS_Runtime::FromContext(cc); |
CPDFSDK_Document* pReaderDoc = pContext->GetReaderDocument(); |
- CPDFSDK_InterForm* pReaderInterForm = pReaderDoc->GetInterForm(); |
+ CPDFSDK_InterForm* pReaderInterForm = pReaderDoc->GetEnv()->GetInterForm(); |
CPDF_InterForm* pInterForm = pReaderInterForm->GetInterForm(); |
CFX_WideString sFunction = params[0].ToCFXWideString(pRuntime); |