summaryrefslogtreecommitdiffstats
path: root/libutils
diff options
context:
space:
mode:
authorMikhail Lappo <miklelappo@gmail.com>2017-06-14 23:11:05 +0000
committerandroid-build-merger <android-build-merger@google.com>2017-06-14 23:11:05 +0000
commitdf36644d6899c91ea481afe167f313996eafe789 (patch)
treec04a0aecfa0b9101006f030b8c57a21b5c06be10 /libutils
parent234e7683d3e7f4b07da892c918ddb1edec565c78 (diff)
parent34b7617cb77e9c63b335cb93bcfe644f178d4481 (diff)
downloadcore-df36644d6899c91ea481afe167f313996eafe789.tar.gz
core-df36644d6899c91ea481afe167f313996eafe789.tar.bz2
core-df36644d6899c91ea481afe167f313996eafe789.zip
Merge "Va_end should be used with va_start" am: 5f4808382e
am: 34b7617cb7 Change-Id: Ibc9fed36270da3f960179086792ce1187be31e92
Diffstat (limited to 'libutils')
-rw-r--r--libutils/Printer.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/libutils/Printer.cpp b/libutils/Printer.cpp
index 12f77bbc1..cbf042eb5 100644
--- a/libutils/Printer.cpp
+++ b/libutils/Printer.cpp
@@ -45,9 +45,11 @@ void Printer::printFormatLine(const char* format, ...) {
#ifndef _WIN32
if (vasprintf(&formattedString, format, arglist) < 0) { // returns -1 on error
ALOGE("%s: Failed to format string", __FUNCTION__);
+ va_end(arglist);
return;
}
#else
+ va_end(arglist);
return;
#endif