| Index: core/src/fxcrt/fx_extension.cpp
|
| diff --git a/core/src/fxcrt/fx_extension.cpp b/core/src/fxcrt/fx_extension.cpp
|
| index fd1ecafe069f24a69c6ad38318edaa7664db1819..4669ac4be429eee3fd7b26a622ac9911c489dba0 100644
|
| --- a/core/src/fxcrt/fx_extension.cpp
|
| +++ b/core/src/fxcrt/fx_extension.cpp
|
| @@ -290,8 +290,7 @@ void FX_Random_GenerateBase(FX_DWORD* pBuffer, int32_t iCount) {
|
| #if _FXM_PLATFORM_ == _FXM_PLATFORM_WINDOWS_
|
| FX_BOOL FX_GenerateCryptoRandom(FX_DWORD* pBuffer, int32_t iCount) {
|
| HCRYPTPROV hCP = NULL;
|
| - if (!::CryptAcquireContext(&hCP, NULL, NULL, PROV_RSA_FULL, 0) ||
|
| - hCP == NULL) {
|
| + if (!::CryptAcquireContext(&hCP, NULL, NULL, PROV_RSA_FULL, 0) || !hCP) {
|
| return FALSE;
|
| }
|
| ::CryptGenRandom(hCP, iCount * sizeof(FX_DWORD), (uint8_t*)pBuffer);
|
|
|