diff options
author | Guilhem Bichot <guilhem@mysql.com> | 2009-08-12 15:44:34 +0200 |
---|---|---|
committer | Guilhem Bichot <guilhem@mysql.com> | 2009-08-12 15:44:34 +0200 |
commit | eceba8912c9af415f9704bb671ddb4022eb8d9fc (patch) | |
tree | 5fdae14ec96fd61b574fe1c8b2d62d304114c53c /sql/sql_update.cc | |
parent | e44bda225abd5a736999b9c73ac88e059d823c2d (diff) | |
parent | 6e7de781d73b8967f1ab9e6c076795dd83429a80 (diff) | |
download | mariadb-git-eceba8912c9af415f9704bb671ddb4022eb8d9fc.tar.gz |
merge of 5.1-main into mysql-trunk.
Changes to ha_innodb.cc are not propagated to plugin, they will come back
via Oracle/Innobase if needed.
Diffstat (limited to 'sql/sql_update.cc')
-rw-r--r-- | sql/sql_update.cc | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/sql/sql_update.cc b/sql/sql_update.cc index d7c9fc83270..6fa4a29c7d2 100644 --- a/sql/sql_update.cc +++ b/sql/sql_update.cc @@ -294,7 +294,7 @@ int mysql_update(THD *thd, if (select_lex->inner_refs_list.elements && fix_inner_refs(thd, all_fields, select_lex, select_lex->ref_pointer_array)) - DBUG_RETURN(-1); + DBUG_RETURN(1); if (conds) { @@ -334,7 +334,14 @@ int mysql_update(THD *thd, { delete select; free_underlaid_joins(thd, select_lex); - if (error) + /* + There was an error or the error was already sent by + the quick select evaluation. + TODO: Add error code output parameter to Item::val_xxx() methods. + Currently they rely on the user checking DA for + errors when unwinding the stack after calling Item::val_xxx(). + */ + if (error || thd->is_error()) { DBUG_RETURN(1); // Error in where } |