mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-10 13:13:44 +01:00
util/map_anon_nofork: Add a cast to avoid passing -48 to memset
This fixes coverity CID 1454593, and bug 31948. Bug not in any released version of Tor.
This commit is contained in:
parent
bca30bcb90
commit
b2802ae3c3
@ -6197,7 +6197,7 @@ test_util_map_anon_nofork(void *arg)
|
||||
tor_munmap_anonymous(ptr, sz);
|
||||
ptr = tor_mmap_anonymous(sz, ANONMAP_NOINHERIT, &inherit);
|
||||
tt_ptr_op(ptr, OP_NE, 0);
|
||||
memset(ptr, TEST_VALUE, sz);
|
||||
memset(ptr, (uint8_t)TEST_VALUE, sz);
|
||||
|
||||
tt_int_op(0, OP_EQ, pipe(pipefd));
|
||||
pid_t child = fork();
|
||||
|
Loading…
Reference in New Issue
Block a user