summaryrefslogtreecommitdiffstats
path: root/src/util
diff options
context:
space:
mode:
authorAndrii Simiklit <[email protected]>2018-09-06 17:43:54 +0300
committerAndres Gomez <[email protected]>2018-09-08 01:02:28 +0300
commit4ddc689d6815db8d226897b9037378fca753f8aa (patch)
treee14c2ea24f1fbd871c0ee57e91968d8feed79ccf /src/util
parent841dc893ca67fe2d35fb2831d48556beb14ee454 (diff)
mesa/util: add missing va_end() after va_copy()
MSDN: "va_end must be called on each argument list that's initialized with va_start or va_copy before the function returns." Reviewed-by: Eric Engestrom <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107810 Fixes: c6267ebd6c8a "gallium/util: Stop bundling our snprintf implementation." Signed-off-by: Andrii Simiklit <[email protected]> (cherry picked from commit 2930b76cfe1e13e84ac0d88f9c6d709a5a8d4c18)
Diffstat (limited to 'src/util')
-rw-r--r--src/util/u_string.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/util/u_string.h b/src/util/u_string.h
index fb43ed0afc3..e4081466459 100644
--- a/src/util/u_string.h
+++ b/src/util/u_string.h
@@ -81,6 +81,7 @@ util_vsnprintf(char *str, size_t size, const char *format, va_list ap)
if (ret < 0) {
ret = _vscprintf(format, ap_copy);
}
+ va_end(ap_copy);
return ret;
}