summaryrefslogtreecommitdiff
path: root/storage/maria/ma_update.c
diff options
context:
space:
mode:
Diffstat (limited to 'storage/maria/ma_update.c')
-rw-r--r--storage/maria/ma_update.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/storage/maria/ma_update.c b/storage/maria/ma_update.c
index 737c7c909b4..913959717fc 100644
--- a/storage/maria/ma_update.c
+++ b/storage/maria/ma_update.c
@@ -147,6 +147,7 @@ int maria_update(register MARIA_HA *info, const byte *oldrec, byte *newrec)
if (share->calc_checksum)
{
info->cur_row.checksum= (*share->calc_checksum)(info,newrec);
+ info->state->checksum+= (info->cur_row.checksum - old_checksum);
/* Store new checksum in index file header */
key_changed|= HA_STATE_CHANGED;
}
@@ -173,8 +174,6 @@ int maria_update(register MARIA_HA *info, const byte *oldrec, byte *newrec)
if (auto_key_changed)
set_if_bigger(info->s->state.auto_increment,
ma_retrieve_auto_increment(info, newrec));
- if (share->calc_checksum)
- info->state->checksum+= (info->cur_row.checksum - old_checksum);
/*
We can't yet have HA_STATE_AKTIV here, as block_record dosn't support