diff options
author | unknown <kostja@bodhi.local> | 2006-07-12 19:19:43 +0400 |
---|---|---|
committer | unknown <kostja@bodhi.local> | 2006-07-12 19:19:43 +0400 |
commit | a7dddd3b67e70292c0813e80ad255f1dc2f3a867 (patch) | |
tree | 10f8e97afe27a3c3ab789092958fe023f239daec | |
parent | a08a6f9f57ae26a9cca02a8623f72a1eaae6ebba (diff) | |
download | mariadb-git-a7dddd3b67e70292c0813e80ad255f1dc2f3a867.tar.gz |
Fix a valgrind warning in type_date test.
sql/item_timefunc.cc:
Fix a valgrind warning in type_date test.
-rw-r--r-- | sql/item_timefunc.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sql/item_timefunc.cc b/sql/item_timefunc.cc index 7dff3000b5b..9e1962835c8 100644 --- a/sql/item_timefunc.cc +++ b/sql/item_timefunc.cc @@ -492,10 +492,11 @@ bool make_date_time(DATE_TIME_FORMAT *format, TIME *l_time, const char *ptr, *end; MY_LOCALE *locale; THD *thd= current_thd; - char buf[128]; - String tmp(buf, thd->variables.character_set_results); + char buf[STRING_BUFFER_USUAL_SIZE]; + String tmp(buf, sizeof(buf), thd->variables.character_set_results); uint errors= 0; + tmp.length(0); str->length(0); str->set_charset(&my_charset_bin); locale = thd->variables.lc_time_names; |