From 0c4b5818d8d705cd8361ad36bba6797d1daaf30d Mon Sep 17 00:00:00 2001 From: Tobias Weimer Date: Tue, 25 Aug 2015 18:34:36 +0000 Subject: added forgotten va_end() git-svn-id: http://svn.miranda-ng.org/main/trunk@15031 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- include/m_core.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/include/m_core.h b/include/m_core.h index 148839e2ce..8238d91b6d 100644 --- a/include/m_core.h +++ b/include/m_core.h @@ -671,7 +671,9 @@ inline int mir_snprintf(char(&buffer)[_Size], const char* fmt, ...) { va_list args; va_start(args, fmt); - return mir_vsnprintf(buffer, _Size, fmt, args); + int ret = mir_vsnprintf(buffer, _Size, fmt, args); + va_end(args); + return ret; } template @@ -679,7 +681,9 @@ inline int mir_snwprintf(wchar_t(&buffer)[_Size], const wchar_t* fmt, ...) { va_list args; va_start(args, fmt); - return mir_vsnwprintf(buffer, _Size, fmt, args); + int ret = mir_vsnwprintf(buffer, _Size, fmt, args); + va_end(args); + return ret; } template -- cgit v1.2.3