query_classifier.cc:parsing_info_done: calling mysql_thread_end caused segfauls when same thread tried next time call free_embedded_thd because thread's sysvar was set to NULL in mysql_thread_end.

Added a few lines to canonical query test's input script which are not handled correctly.
This commit is contained in:
VilhoRaatikka
2014-08-25 22:17:21 +03:00
parent 2694c69186
commit c5fbb1f295
3 changed files with 6 additions and 4 deletions

View File

@ -964,9 +964,8 @@ parsing_info_t* parsing_info_init(
mysql_errno(mysql),
mysql_error(mysql))));
mysql_library_end();
goto retblock;
}
}
/** Set methods and authentication to mysql */
mysql_options(mysql, MYSQL_READ_DEFAULT_GROUP, "libmysqld_skygw");
mysql_options(mysql, MYSQL_OPT_USE_EMBEDDED_CONNECTION, NULL);
@ -1019,7 +1018,6 @@ void parsing_info_done(
mysql->thd = NULL;
}
mysql_close(mysql);
mysql_thread_end();
}
/** Free plain text query string */
if (pi->pi_query_plain_str != NULL)