MDEV-36373 Bogus Warning: ... storage is corrupted

ha_innobase::statistics_init(), ha_innobase::info_low():
Correctly handle a DB_READ_ONLY return value from dict_stats_save().
Fixes up commit 6e6a1b316c (MDEV-35000)
This commit is contained in:
Marko Mäkelä 2025-03-25 08:48:08 +02:00
commit 33a462e0b1
3 changed files with 21 additions and 1 deletions

View file

@ -5872,7 +5872,7 @@ dberr_t ha_innobase::statistics_init(dict_table_t *table, bool recalc)
if (err == DB_STATS_DO_NOT_EXIST && table->stats_is_auto_recalc())
goto recalc;
}
if (err == DB_SUCCESS)
if (err == DB_SUCCESS || err == DB_READ_ONLY)
return err;
if (!recalc)
break;
@ -14934,6 +14934,7 @@ recalc:
ret = statistics_init(ib_table, is_analyze);
switch (ret) {
case DB_SUCCESS:
case DB_READ_ONLY:
break;
default:
goto error;