From 5b6c96202b5300d92b49ec644113061b5f67d7c1 Mon Sep 17 00:00:00 2001 From: unknown Date: Sun, 24 Jun 2001 19:51:20 +0300 Subject: sync0sync.c Do not use in-line assembly in GCC srv0start.c Eliminate a deadlock of threads at startup row0mysql.c Several bug fixes row0umod.c Several bug fixes row0upd.c Several bug fixes os0file.c Revert back to fsync as default flush method log0recv.c Several bug fixes ibuf0ibuf.c Several bug fixes fsp0fsp.c Several bug fixes trx0undo.c Put some assertions to uncover possible bugs dict0boot.c Several bug fixes innobase/dict/dict0boot.c: Several bug fixes innobase/trx/trx0undo.c: Put some assertions to uncover possible bugs innobase/fsp/fsp0fsp.c: Several bug fixes innobase/ibuf/ibuf0ibuf.c: Several bug fixes innobase/log/log0recv.c: Several bug fixes innobase/os/os0file.c: Revert back to fsync as default flush method innobase/row/row0mysql.c: Several bug fixes innobase/row/row0umod.c: Several bug fixes innobase/row/row0upd.c: Several bug fixes innobase/srv/srv0start.c: Eliminate a deadlock of threads at startup innobase/sync/sync0sync.c: Do not use in-line assembly in GCC --- innobase/row/row0upd.c | 30 +++++++++++++++++++++++++----- 1 file changed, 25 insertions(+), 5 deletions(-) (limited to 'innobase/row/row0upd.c') diff --git a/innobase/row/row0upd.c b/innobase/row/row0upd.c index 10dd64b8b1a..5bca2a24c01 100644 --- a/innobase/row/row0upd.c +++ b/innobase/row/row0upd.c @@ -750,6 +750,7 @@ row_upd_sec_index_entry( btr_cur_t* btr_cur; mem_heap_t* heap; rec_t* rec; + char* err_buf; ulint err = DB_SUCCESS; index = node->index; @@ -764,18 +765,37 @@ row_upd_sec_index_entry( found = row_search_index_entry(index, entry, BTR_MODIFY_LEAF, &pcur, &mtr); - ut_ad(found); - btr_cur = btr_pcur_get_btr_cur(&pcur); rec = btr_cur_get_rec(btr_cur); - /* Delete mark the old index record; it can already be delete marked if - we return after a lock wait in row_ins_index_entry below */ + if (!found) { + + err_buf = mem_alloc(1000); + dtuple_sprintf(err_buf, 900, entry); + + fprintf(stderr, "InnoDB: error in sec index entry update in\n" + "InnoDB: index %s table %s\n", index->name, + index->table->name); + fprintf(stderr, "InnoDB: tuple %s\n", err_buf); + + rec_sprintf(err_buf, 900, rec); + fprintf(stderr, "InnoDB: record %s\n", err_buf); + + fprintf(stderr, "InnoDB: Make a detailed bug report and send it\n"); + fprintf(stderr, "InnoDB: to mysql@lists.mysql.com\n"); + + mem_free(err_buf); + } else { + + /* Delete mark the old index record; it can already be + delete marked if we return after a lock wait in + row_ins_index_entry below */ - if (!rec_get_deleted_flag(rec)) { + if (!rec_get_deleted_flag(rec)) { err = btr_cur_del_mark_set_sec_rec(0, btr_cur, TRUE, thr, &mtr); + } } btr_pcur_close(&pcur); -- cgit v1.2.1