diff options
Diffstat (limited to 'xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp')
-rw-r--r-- | xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp b/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp index 3412aa258b..bf2aa0ccbe 100644 --- a/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp +++ b/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp @@ -5437,12 +5437,10 @@ void CXFA_FM2JSContext::Get(FXJSE_HOBJECT hThis, if (pFile) {
int32_t size = pFile->GetSize();
uint8_t* pData = FX_Alloc(uint8_t, size);
- if (pData) {
- pFile->ReadBlock(pData, size);
- FXJSE_Value_SetUTF8String(args.GetReturnValue(),
- CFX_ByteStringC(pData, size));
- FX_Free(pData);
- }
+ pFile->ReadBlock(pData, size);
+ FXJSE_Value_SetUTF8String(args.GetReturnValue(),
+ CFX_ByteStringC(pData, size));
+ FX_Free(pData);
pFile->Release();
}
FXJSE_Value_Release(argOne);
|