mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2024-11-22 01:19:52 +03:00
Merge PR #1273: fix null pointer dereference found by ErrorSanitizer
This commit is contained in:
commit
ea2c8f9861
@ -1840,6 +1840,10 @@ LOCK *UnixNewLock()
|
||||
|
||||
// Create a mutex
|
||||
mutex = UnixMemoryAlloc(sizeof(pthread_mutex_t));
|
||||
if (mutex == NULL)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// Initialization of the mutex
|
||||
pthread_mutex_init(mutex, NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user