summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorunknown <kent@kent-amd64.(none)>2008-02-09 12:17:19 +0100
committerunknown <kent@kent-amd64.(none)>2008-02-09 12:17:19 +0100
commit5fa560e995a01c87bd7d20264c85c2ec66c19748 (patch)
treeb9631baa3b44271ed0f2c102ca2992af7681bc2c /sql
parente9a89f123ea45c255a91e3b258acba0b61701e82 (diff)
parentafa95c688b90d9d758125f919ec9cdd2fa392f86 (diff)
downloadmariadb-git-5fa560e995a01c87bd7d20264c85c2ec66c19748.tar.gz
Merge kboortz@bk-internal.mysql.com:/home/bk/mysql-maria
into mysql.com:/home/kent/bk/maria/mysql-maria
Diffstat (limited to 'sql')
-rw-r--r--sql/handler.cc2
-rw-r--r--sql/log_event.cc20
2 files changed, 15 insertions, 7 deletions
diff --git a/sql/handler.cc b/sql/handler.cc
index 17b6e943f17..e514a079cd4 100644
--- a/sql/handler.cc
+++ b/sql/handler.cc
@@ -4032,6 +4032,8 @@ int handler::ha_reset()
DBUG_ASSERT(inited == NONE);
/* Free cache used by filesort */
free_io_cache(table);
+ /* reset the bitmaps to point to defaults */
+ table->default_column_bitmaps();
DBUG_RETURN(reset());
}
diff --git a/sql/log_event.cc b/sql/log_event.cc
index df0d1e8a020..a4b32a84b42 100644
--- a/sql/log_event.cc
+++ b/sql/log_event.cc
@@ -8031,7 +8031,7 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
{
DBUG_PRINT("info",("ha_index_init returns error %d",error));
table->file->print_error(error, MYF(0));
- DBUG_RETURN(error);
+ goto err;
}
/* Fill key data for the row */
@@ -8064,7 +8064,7 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
DBUG_PRINT("info",("no record matching the key found in the table"));
table->file->print_error(error, MYF(0));
table->file->ha_index_end();
- DBUG_RETURN(error);
+ goto err;
}
/*
@@ -8092,7 +8092,7 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
if (table->key_info->flags & HA_NOSAME)
{
table->file->ha_index_end();
- DBUG_RETURN(0);
+ goto ok;
}
/*
@@ -8124,7 +8124,7 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
DBUG_PRINT("info",("no record matching the given row found"));
table->file->print_error(error, MYF(0));
table->file->ha_index_end();
- DBUG_RETURN(error);
+ goto err;
}
}
@@ -8145,7 +8145,7 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
DBUG_PRINT("info",("error initializing table scan"
" (ha_rnd_init returns %d)",error));
table->file->print_error(error, MYF(0));
- DBUG_RETURN(error);
+ goto err;
}
/* Continue until we find the right record or have made a full loop */
@@ -8169,7 +8169,7 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
" (rnd_next returns %d)",error));
table->file->print_error(error, MYF(0));
table->file->ha_rnd_end();
- DBUG_RETURN(error);
+ goto err;
}
}
while (restart_count < 2 && record_compare(table));
@@ -8189,10 +8189,16 @@ int Rows_log_event::find_row(const Relay_log_info *rli)
table->file->ha_rnd_end();
DBUG_ASSERT(error == HA_ERR_END_OF_FILE || error == HA_ERR_RECORD_DELETED || error == 0);
- DBUG_RETURN(error);
+ goto err;
}
+ok:
+ table->default_column_bitmaps();
DBUG_RETURN(0);
+
+err:
+ table->default_column_bitmaps();
+ DBUG_RETURN(error);
}
#endif