| Index: fpdfsdk/javascript/JS_GlobalData.cpp
|
| diff --git a/fpdfsdk/javascript/JS_GlobalData.cpp b/fpdfsdk/javascript/JS_GlobalData.cpp
|
| index 14c36530d5d65c2d2483596f16de47b514ce8bf8..fb470a02ebf1f74122dc47e963ce5880f08fbf35 100644
|
| --- a/fpdfsdk/javascript/JS_GlobalData.cpp
|
| +++ b/fpdfsdk/javascript/JS_GlobalData.cpp
|
| @@ -100,21 +100,21 @@ static bool TrimPropName(CFX_ByteString* sPropName) {
|
| return sPropName->GetLength() != 0;
|
| }
|
|
|
| -CJS_GlobalData* CJS_GlobalData::g_Instance = nullptr;
|
| +CJS_GlobalData* CJS_GlobalData::m_pInstance = nullptr;
|
|
|
| // static
|
| CJS_GlobalData* CJS_GlobalData::GetRetainedInstance(CPDFDoc_Environment* pApp) {
|
| - if (!g_Instance) {
|
| - g_Instance = new CJS_GlobalData();
|
| + if (!m_pInstance) {
|
| + m_pInstance = new CJS_GlobalData();
|
| }
|
| - ++g_Instance->m_RefCount;
|
| - return g_Instance;
|
| + ++m_pInstance->m_RefCount;
|
| + return m_pInstance;
|
| }
|
|
|
| void CJS_GlobalData::Release() {
|
| if (!--m_RefCount) {
|
| - delete g_Instance;
|
| - g_Instance = nullptr;
|
| + delete m_pInstance;
|
| + m_pInstance = nullptr;
|
| }
|
| }
|
|
|
|
|