mirror of
https://github.com/samba-team/samba.git
synced 2025-01-10 01:18:15 +03:00
ctdb-utils: Fix CID 1297451 Explicit null dereferenced (FORWARD_NULL)
Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
This commit is contained in:
parent
aff33a5947
commit
d46960f20e
@ -142,7 +142,9 @@ static void ping_pong(int fd, int num_locks)
|
||||
val = (unsigned char *)calloc(num_locks+1, sizeof(unsigned char));
|
||||
if (val == NULL) {
|
||||
printf("calloc failed\n");
|
||||
munmap(p, num_locks+1);
|
||||
if (use_mmap) {
|
||||
munmap(p, num_locks+1);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user