Jesuiter, Henry (ALC NetworX GmbH)
2016-07-08 09:41:16 UTC
--
Since size_t is an unsigned data type, it won't evaluate correctly on errors
of vasprintf(). This patch makes 'len2' a signed integer, as expected by
vasprintf().
Signed-off-by: Henry Jesuiter <***@alcnetworx.de>
---
diff -rwbBu a/util.c b/util.c
--- a/util.c 2015-09-19 16:25:11.000000000 +0200
+++ b/util.c 2016-07-08 11:33:09.843328724 +0200
@@ -448,7 +448,8 @@
void string_appendf(char **s, const char *format, ...)
{
va_list ap;
- size_t len1, len2;
+ size_t len1;
+ int len2;
char *s2;
len1 = strlen(*s);
---
Best regards
Henry Jesuiter
Since size_t is an unsigned data type, it won't evaluate correctly on errors
of vasprintf(). This patch makes 'len2' a signed integer, as expected by
vasprintf().
Signed-off-by: Henry Jesuiter <***@alcnetworx.de>
---
diff -rwbBu a/util.c b/util.c
--- a/util.c 2015-09-19 16:25:11.000000000 +0200
+++ b/util.c 2016-07-08 11:33:09.843328724 +0200
@@ -448,7 +448,8 @@
void string_appendf(char **s, const char *format, ...)
{
va_list ap;
- size_t len1, len2;
+ size_t len1;
+ int len2;
char *s2;
len1 = strlen(*s);
---
Best regards
Henry Jesuiter