diff options
author | unknown <ram@gw.mysql.r18.ru> | 2004-10-01 16:23:54 +0500 |
---|---|---|
committer | unknown <ram@gw.mysql.r18.ru> | 2004-10-01 16:23:54 +0500 |
commit | 18ba5fb8e619068af6b116ae5a0cbbc70fcf4a72 (patch) | |
tree | 6b8e8f20338796d2bc1824b13e295b5dfa3b81ca /sql/records.cc | |
parent | cb639faffb04e3fe3c657e90a71cc9b5a7471d0b (diff) | |
download | mariadb-git-18ba5fb8e619068af6b116ae5a0cbbc70fcf4a72.tar.gz |
delete.result, delete.test:
A fix (bug #5733: Table handler error with self-join multi-table DELETE).
records.cc:
A fix (bug #5733: Table handler error with self-join multi-table DELETE).
sql/records.cc:
]A fix (bug #5733: Table handler error with self-join multi-table DELETE).
mysql-test/t/delete.test:
A fix (bug #5733: Table handler error with self-join multi-table DELETE).
mysql-test/r/delete.result:
A fix (bug #5733: Table handler error with self-join multi-table DELETE).
Diffstat (limited to 'sql/records.cc')
-rw-r--r-- | sql/records.cc | 27 |
1 files changed, 18 insertions, 9 deletions
diff --git a/sql/records.cc b/sql/records.cc index 415e75a467b..02ae2e06141 100644 --- a/sql/records.cc +++ b/sql/records.cc @@ -131,17 +131,26 @@ void end_read_record(READ_RECORD *info) static int rr_quick(READ_RECORD *info) { - int tmp=info->select->quick->get_next(); - if (tmp) + int tmp; + while ((tmp= info->select->quick->get_next())) { - if (tmp == HA_ERR_END_OF_FILE) - tmp= -1; - else + if (info->thd->killed) { - if (info->print_error) - info->file->print_error(tmp,MYF(0)); - if (tmp < 0) // Fix negative BDB errno - tmp=1; + my_error(ER_SERVER_SHUTDOWN, MYF(0)); + return 1; + } + if (tmp != HA_ERR_RECORD_DELETED) + { + if (tmp == HA_ERR_END_OF_FILE) + tmp= -1; + else + { + if (info->print_error) + info->file->print_error(tmp,MYF(0)); + if (tmp < 0) // Fix negative BDB errno + tmp=1; + } + break; } } return tmp; |