• unknown's avatar
    BUG#29207 - archive table reported as corrupt by check table (P1) · a38b1ae7
    unknown authored
    CHECK TABLE against ARCHIVE table may falsely report table corruption,
    or cause server crash.
    
    Fixed by using proper buffer for CHECK TABLE.
    
    Affects both 5.0 and 5.1.
    
    
    mysql-test/r/archive.result:
      A test case for BUG#28916.
    mysql-test/t/archive.test:
      A test case for BUG#28916.
    sql/ha_archive.cc:
      We call Field::get_length() from get_row(). Field::get_length() assumes
      that the row was read into table->record[0] buffer, which is not the
      case when we check a table. As a result we get wrongly initialized
      blob length.
      
      Use table->record[0] as record buffer for check table instead.
    a38b1ae7
ha_archive.cc 35.2 KB