]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Remove a few useless asserts after memory allocation.
authorFlorian Krohm <florian@eich-krohm.de>
Thu, 18 Sep 2014 18:34:19 +0000 (18:34 +0000)
committerFlorian Krohm <florian@eich-krohm.de>
Thu, 18 Sep 2014 18:34:19 +0000 (18:34 +0000)
The called allocators don't return NULL.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@14553

coregrind/m_debuginfo/misc.c

index 430d4357f07e351caba783745f0ac20c308e5ce7..271fd0103d62bee6e31b2945cc9184ad36d76c5c 100644 (file)
@@ -46,7 +46,6 @@ void* ML_(dinfo_zalloc) ( const HChar* cc, SizeT szB ) {
    void* v;
    vg_assert(szB > 0);
    v = VG_(arena_malloc)( VG_AR_DINFO, cc, szB );
-   vg_assert(v);
    VG_(memset)(v, 0, szB);
    return v;
 }
@@ -65,7 +64,6 @@ HChar* ML_(dinfo_strdup) ( const HChar* cc, const HChar* str ) {
 
 void* ML_(dinfo_memdup) ( const HChar* cc, void* str, SizeT nStr ) {
    void* dst = VG_(arena_malloc)( VG_AR_DINFO, cc, nStr );
-   vg_assert(dst);
    VG_(memcpy)(dst, str, nStr);
    return dst;
 }