• Satya B's avatar
    Fix for BUG#41541 - Valgrind warnings on packed MyISAM table · 7b1d72a0
    Satya B authored
                
    After the table is compressed by the myisampack utility,
    opening the table by the server produces valgrind warnings.
          
    This happens because when we try to read a record into the buffer
    we alway assume that the remaining buffer to read is always equal 
    to word size(4 or 8 or 2 bytes) we read. Sometimes we have 
    remaining buffer size less than word size and trying to read the 
    entire word size will end up in valgrind errors.
                
    Fixed by reading byte by byte when we detect the remaining buffer 
    size is less than the word size.
    7b1d72a0
mi_packrec.c 49.8 KB