diff options
Diffstat (limited to 'crypto/async/arch')
-rw-r--r-- | crypto/async/arch/async_posix.c | 3 | ||||
-rw-r--r-- | crypto/async/arch/async_win.c | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/crypto/async/arch/async_posix.c b/crypto/async/arch/async_posix.c index 814930f7bb..78bf61c44e 100644 --- a/crypto/async/arch/async_posix.c +++ b/crypto/async/arch/async_posix.c @@ -76,7 +76,8 @@ int async_fibre_init(async_fibre *fibre) { void *stack = NULL; - if (!(stack = OPENSSL_malloc(STACKSIZE))) { + stack = OPENSSL_malloc(STACKSIZE); + if (stack == NULL) { return 0; } diff --git a/crypto/async/arch/async_win.c b/crypto/async/arch/async_win.c index 5cb14ce986..fce3c481d6 100644 --- a/crypto/async/arch/async_win.c +++ b/crypto/async/arch/async_win.c @@ -72,7 +72,7 @@ int async_fibre_init_dispatcher(async_fibre *fibre) dispatcher = (LPVOID) CRYPTO_get_thread_local(CRYPTO_THREAD_LOCAL_ASYNC_DISPATCH); - if (!dispatcher) { + if (dispatcher == NULL) { fibre->fibre = ConvertThreadToFiber(NULL); CRYPTO_set_thread_local(CRYPTO_THREAD_LOCAL_ASYNC_DISPATCH, (void *)fibre->fibre); @@ -125,7 +125,7 @@ int async_set_pool(STACK_OF(ASYNC_JOB) *poolin, size_t curr_size, { struct winpool *pool; pool = OPENSSL_malloc(sizeof *pool); - if (!pool) + if (pool == NULL) return 0; pool->pool = poolin; |