Skip to content

Commit

Permalink
Tools: hv: fix snprintf warning in kvp_daemon
Browse files Browse the repository at this point in the history
Increase buffer size so that "_{-INT_MAX}" will fit.
Spotted by the gcc7 snprintf checker.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Olaf Hering authored and Greg Kroah-Hartman committed Aug 16, 2017
1 parent ddce54b commit 3619350
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/hv/hv_kvp_daemon.c
Original file line number Diff line number Diff line change
Expand Up @@ -1136,7 +1136,7 @@ static int process_ip_string(FILE *f, char *ip_string, int type)
int i = 0;
int j = 0;
char str[256];
char sub_str[10];
char sub_str[13];
int offset = 0;

memset(addr, 0, sizeof(addr));
Expand Down

0 comments on commit 3619350

Please sign in to comment.