diff options
author | Tobias Weimer <wishmaster51@googlemail.com> | 2015-08-25 18:34:36 +0000 |
---|---|---|
committer | Tobias Weimer <wishmaster51@googlemail.com> | 2015-08-25 18:34:36 +0000 |
commit | 0c4b5818d8d705cd8361ad36bba6797d1daaf30d (patch) | |
tree | a7397a13343e08a83e40199480fab56cd8457b4a | |
parent | 6201b43c9ac829da93f96d11ecdf5a94d3990ed4 (diff) |
added forgotten va_end()
git-svn-id: http://svn.miranda-ng.org/main/trunk@15031 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r-- | include/m_core.h | 8 |
1 files 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 <size_t _Size>
@@ -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 <size_t _Size>
|