• marko's avatar
    branches/zip: Improve Valgrind diagnostics. · b91b8f49
    marko authored
    buf_buddy_relocate(): Document that src may have been split and some of
    it may be in buf_pool->zip_free[j] for some j<i, thus mach_read_from_4()
    may be reading from free memory.  Check buffer pages only for addressability,
    not for being completely initialized.  Ensure that block descriptors are
    completely initialized.
    
    buf_buddy_remove_from_free(): Check prev->state and next->state in
    UNIV_DEBUG && UNIV_DEBUG_VALGRIND builds.
    
    buf_buddy_free_low(): Flag the entire block valid prior to invoking
    buf_buddy_remove_from_free() in order to avoid a Valgrind warning about
    the debug assertion on bpage->state.  Remove the Valgrind check for
    buddy being completely allocated.  If it has been split to smaller blocks,
    some of those blocks may be free.
    b91b8f49
buf0buddy.c 19.2 KB