• Marko Mäkelä's avatar
    MDEV-13542: Do not crash on decryption failure · 892c4263
    Marko Mäkelä authored
    fil_page_type_validate(): Remove. This debug check was mostly redundant
    and added little value to the code paths that deal with page_compressed
    or encrypted pages.
    
    fil_get_page_type_name(): Remove; unused function.
    
    fil_space_decrypt(): Return an error if the page is not
    supposed to be encrypted. It is possible that an unencrypted page
    contains a nonzero key_version field even though it is not supposed
    to be encrypted. Previously we would crash in such a situation.
    
    buf_page_decrypt_after_read(): Simplify the code. Remove some
    unnecessary error message about temporary tablespace corruption.
    This is where we would usually invoke fil_space_decrypt().
    892c4263
buf0buf.cc 120 KB