summaryrefslogtreecommitdiff
path: root/sql/sql_update.cc
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2005-02-02 20:28:01 +0200
committerunknown <monty@mysql.com>2005-02-02 20:28:01 +0200
commit3d0f9d96d7236af2c4dc4bf844233e27497d59dc (patch)
tree816f40ac6d333fd1385b716ade92694569d78674 /sql/sql_update.cc
parent613c2f68e2c8de50be8caafac20256940990987e (diff)
downloadmariadb-git-3d0f9d96d7236af2c4dc4bf844233e27497d59dc.tar.gz
Fixed during review of new pulled code
extra/perror.c: Use strmov() instead of strcpy() Indentation fixes sql/sql_table.cc: Revert back part of the old code as the new code didn't use mysql_data_home, which would have caused problems in the embedded server sql/sql_update.cc: Ensure that used_index is always set (It has to be set because it's value is tested if order != 0)
Diffstat (limited to 'sql/sql_update.cc')
-rw-r--r--sql/sql_update.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/sql_update.cc b/sql/sql_update.cc
index 0ec71bdfba3..663f2d2be34 100644
--- a/sql/sql_update.cc
+++ b/sql/sql_update.cc
@@ -167,7 +167,10 @@ int mysql_update(THD *thd,
else if ((used_index=table->file->key_used_on_scan) < MAX_KEY)
used_key_is_modified=check_if_key_used(table, used_index, fields);
else
+ {
used_key_is_modified=0;
+ used_index= MAX_KEY;
+ }
if (used_key_is_modified || order)
{
/*