Skip to content

Commit

Permalink
Bug#15960005 VALGRIND WARNINGS IN PROCESS_ARGS
Browse files Browse the repository at this point in the history
  Both <width> and <precision> can be specified as numbers or '*'.
  If an asterisk is used, an argument of type int is consumed.

--BZR--
revision-id: [email protected]
property-audit-revid: [email protected]
property-branch-nick: 5.5
property-rebase-of: [email protected]
testament3-sha1: f4a0022cb8ede1989fb1fae4d4678aba4a081beb
  • Loading branch information
Tor Didriksen committed Dec 10, 2012
1 parent e801188 commit 948e1f0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions include/mysql/service_my_snprintf.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
string will be quoted according to MySQL identifier quoting rules.
Both <width> and <precision> can be specified as numbers or '*'.
If an asterisk is used, an argument of type int is consumed.
<length modifier> can be 'l', 'll', or 'z'.
Expand Down
2 changes: 2 additions & 0 deletions strings/my_vsnprintf.c
Original file line number Diff line number Diff line change
Expand Up @@ -343,6 +343,7 @@ static char *process_args(CHARSET_INFO *cs, char *to, char *end,
print_arr[idx].length--;
DBUG_ASSERT(*fmt == '$' && print_arr[idx].length < MAX_ARGS);
args_arr[print_arr[idx].length].arg_type= 'd';
args_arr[print_arr[idx].length].have_longlong= 0;
print_arr[idx].flags|= LENGTH_ARG;
arg_count= max(arg_count, print_arr[idx].length + 1);
fmt++;
Expand All @@ -361,6 +362,7 @@ static char *process_args(CHARSET_INFO *cs, char *to, char *end,
print_arr[idx].width--;
DBUG_ASSERT(*fmt == '$' && print_arr[idx].width < MAX_ARGS);
args_arr[print_arr[idx].width].arg_type= 'd';
args_arr[print_arr[idx].width].have_longlong= 0;
print_arr[idx].flags|= WIDTH_ARG;
arg_count= max(arg_count, print_arr[idx].width + 1);
fmt++;
Expand Down

0 comments on commit 948e1f0

Please sign in to comment.