diff options
-rw-r--r-- | sql/sql_class.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc index 7327f270c33..489bf3b654b 100644 --- a/sql/sql_class.cc +++ b/sql/sql_class.cc @@ -308,7 +308,8 @@ THD *thd_get_current_thd() void thd_clear_errors(THD *thd) { my_errno= 0; - thd->mysys_var->abort= 0; + if (thd->mysys_var) + thd->mysys_var->abort= 0; } |