mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-03 10:05:29 +00:00
VG_(memset) cannot handle NULL pointers and needs to be guarded.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13556
This commit is contained in:
parent
6d15b5deb4
commit
2ffd73f178
@ -2200,7 +2200,8 @@ void* VG_(arena_calloc) ( ArenaId aid, const HChar* cc,
|
||||
|
||||
p = VG_(arena_malloc) ( aid, cc, size );
|
||||
|
||||
VG_(memset)(p, 0, size);
|
||||
if (p != NULL)
|
||||
VG_(memset)(p, 0, size);
|
||||
|
||||
return p;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user