]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Don't skip the top frame when picking up ExeContexts for malloc etc.
authorJulian Seward <jseward@acm.org>
Tue, 16 Apr 2002 01:10:18 +0000 (01:10 +0000)
committerJulian Seward <jseward@acm.org>
Tue, 16 Apr 2002 01:10:18 +0000 (01:10 +0000)
This restores the pre-pthread-merge behaviour.

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

coregrind/vg_clientmalloc.c
vg_clientmalloc.c

index eb450dfe16c4984e6fc29758e2a116a92bcd1614..132fb50adaa944ab7530bae980c56478605d09b9 100644 (file)
@@ -230,7 +230,7 @@ static ShadowChunk* client_malloc_shadow ( ThreadState* tst,
       p = (Addr)VG_(malloc_aligned)(VG_AR_CLIENT, align, size);
 
    sc        = VG_(malloc)(VG_AR_PRIVATE, sizeof(ShadowChunk));
-   sc->where = VG_(get_ExeContext)(True, tst->m_eip, tst->m_ebp);
+   sc->where = VG_(get_ExeContext)(False, tst->m_eip, tst->m_ebp);
    sc->size  = size;
    sc->allockind = kind;
    sc->data  = p;
@@ -351,7 +351,7 @@ void VG_(client_free) ( ThreadState* tst, void* ptrV, VgAllocKind kind )
    VGM_(make_noaccess) ( sc->data - VG_AR_CLIENT_REDZONE_SZB, 
                          sc->size + 2*VG_AR_CLIENT_REDZONE_SZB );
    VGM_(make_noaccess) ( (Addr)sc, sizeof(ShadowChunk) );
-   sc->where = VG_(get_ExeContext)(True, tst->m_eip, tst->m_ebp);
+   sc->where = VG_(get_ExeContext)(False, tst->m_eip, tst->m_ebp);
 
    /* Put it out of harm's way for a while. */
    add_to_freed_queue ( sc );
@@ -387,7 +387,7 @@ void* VG_(client_calloc) ( ThreadState* tst, UInt nmemb, UInt size1 )
    size      = nmemb * size1;
    p         = (Addr)VG_(malloc)(VG_AR_CLIENT, size);
    sc        = VG_(malloc)(VG_AR_PRIVATE, sizeof(ShadowChunk));
-   sc->where = VG_(get_ExeContext)(True, tst->m_eip, tst->m_ebp);
+   sc->where = VG_(get_ExeContext)(False, tst->m_eip, tst->m_ebp);
    sc->size  = size;
    sc->allockind = Vg_AllocMalloc; /* its a lie - but true. eat this :) */
    sc->data  = p;
index eb450dfe16c4984e6fc29758e2a116a92bcd1614..132fb50adaa944ab7530bae980c56478605d09b9 100644 (file)
@@ -230,7 +230,7 @@ static ShadowChunk* client_malloc_shadow ( ThreadState* tst,
       p = (Addr)VG_(malloc_aligned)(VG_AR_CLIENT, align, size);
 
    sc        = VG_(malloc)(VG_AR_PRIVATE, sizeof(ShadowChunk));
-   sc->where = VG_(get_ExeContext)(True, tst->m_eip, tst->m_ebp);
+   sc->where = VG_(get_ExeContext)(False, tst->m_eip, tst->m_ebp);
    sc->size  = size;
    sc->allockind = kind;
    sc->data  = p;
@@ -351,7 +351,7 @@ void VG_(client_free) ( ThreadState* tst, void* ptrV, VgAllocKind kind )
    VGM_(make_noaccess) ( sc->data - VG_AR_CLIENT_REDZONE_SZB, 
                          sc->size + 2*VG_AR_CLIENT_REDZONE_SZB );
    VGM_(make_noaccess) ( (Addr)sc, sizeof(ShadowChunk) );
-   sc->where = VG_(get_ExeContext)(True, tst->m_eip, tst->m_ebp);
+   sc->where = VG_(get_ExeContext)(False, tst->m_eip, tst->m_ebp);
 
    /* Put it out of harm's way for a while. */
    add_to_freed_queue ( sc );
@@ -387,7 +387,7 @@ void* VG_(client_calloc) ( ThreadState* tst, UInt nmemb, UInt size1 )
    size      = nmemb * size1;
    p         = (Addr)VG_(malloc)(VG_AR_CLIENT, size);
    sc        = VG_(malloc)(VG_AR_PRIVATE, sizeof(ShadowChunk));
-   sc->where = VG_(get_ExeContext)(True, tst->m_eip, tst->m_ebp);
+   sc->where = VG_(get_ExeContext)(False, tst->m_eip, tst->m_ebp);
    sc->size  = size;
    sc->allockind = Vg_AllocMalloc; /* its a lie - but true. eat this :) */
    sc->data  = p;