diff options
Diffstat (limited to 'Source/charon/threads')
-rw-r--r-- | Source/charon/threads/thread_pool.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/charon/threads/thread_pool.c b/Source/charon/threads/thread_pool.c index c22f5fe05..dc60deb61 100644 --- a/Source/charon/threads/thread_pool.c +++ b/Source/charon/threads/thread_pool.c @@ -348,6 +348,10 @@ thread_pool_t *thread_pool_create(size_t pool_size) int current; private_thread_pool_t *this = allocator_alloc_thing(private_thread_pool_t); + if (this == NULL) + { + return NULL; + } /* fill in public fields */ this->public.destroy = (status_t(*)(thread_pool_t*))destroy; |