From 94ad392fd86b53f798c7de9489afe901e1f3a9b6 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 21 Oct 2013 13:45:49 +0300 Subject: MDEV-5143: update of a joined table with a nested subquery with a syntax error crashes mysqld with signal 11 Added check of SELECT_LEX::handle_derived() result. --- sql/sql_derived.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'sql/sql_derived.cc') diff --git a/sql/sql_derived.cc b/sql/sql_derived.cc index db6ab1fb269..9d04beaf73e 100644 --- a/sql/sql_derived.cc +++ b/sql/sql_derived.cc @@ -619,7 +619,8 @@ bool mysql_derived_prepare(THD *thd, LEX *lex, TABLE_LIST *derived) { sl->context.outer_context= 0; // Prepare underlying views/DT first. - sl->handle_derived(lex, DT_PREPARE); + if ((res= sl->handle_derived(lex, DT_PREPARE))) + goto exit; if (derived->outer_join) { -- cgit v1.2.1