diff options
author | Guilhem Bichot <guilhem@mysql.com> | 2009-03-11 16:32:42 +0100 |
---|---|---|
committer | Guilhem Bichot <guilhem@mysql.com> | 2009-03-11 16:32:42 +0100 |
commit | b0fcbc84ef609b1147c3624e90fe3dac66ef8c1d (patch) | |
tree | ee09976ab4dd9dee924a4c7e30eb0fc9f5e7d63f /sql/sql_parse.cc | |
parent | a15d25f07e56cbd80aecbeadef635d3b55e00e85 (diff) | |
parent | 11570d64fcffa66feaf1fdb8072fdfb9dbd865ca (diff) | |
download | mariadb-git-b0fcbc84ef609b1147c3624e90fe3dac66ef8c1d.tar.gz |
merge of 5.1-main into 5.1-maria; MyISAM changes are also ported to Maria.
Diffstat (limited to 'sql/sql_parse.cc')
-rw-r--r-- | sql/sql_parse.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index ae9ac38d39f..8536f2308c9 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -5475,9 +5475,10 @@ bool check_stack_overrun(THD *thd, long margin, if ((stack_used=used_stack(thd->thread_stack,(char*) &stack_used)) >= (long) (my_thread_stack_size - margin)) { - sprintf(errbuff[0],ER(ER_STACK_OVERRUN_NEED_MORE), - stack_used,my_thread_stack_size,margin); - my_message(ER_STACK_OVERRUN_NEED_MORE,errbuff[0],MYF(0)); + char ebuff[MYSQL_ERRMSG_SIZE]; + my_snprintf(ebuff, sizeof(ebuff), ER(ER_STACK_OVERRUN_NEED_MORE), + stack_used, my_thread_stack_size, margin); + my_message(ER_STACK_OVERRUN_NEED_MORE, ebuff, MYF(ME_FATALERROR)); thd->fatal_error(); return 1; } |