mdbx-test: workaroung for MSVC bug.

This commit is contained in:
Leo Yuriev 2018-09-14 15:13:05 +03:00
parent 5a461a84e0
commit 6043181636
2 changed files with 4 additions and 4 deletions

View File

@ -57,7 +57,7 @@ static void mdbx_logger(int type, const char *function, int line,
if (logging::output( if (logging::output(
level, level,
strncmp(function, "mdbx_", 5) == 0 ? "%s: " : "mdbx: %s: ", function)) strncmp(function, "mdbx_", 5) == 0 ? "%s: " : "mdbx: %s: ", function))
logging::feed(msg, args); logging::feed_ap(msg, args);
if (type & MDBX_DBG_ASSERT) if (type & MDBX_DBG_ASSERT)
abort(); abort();
} }
@ -193,7 +193,7 @@ bool output(const logging::loglevel priority, const char *format, va_list ap) {
return true; return true;
} }
bool feed(const char *format, va_list ap) { bool feed_ap(const char *format, va_list ap) {
if (!last) if (!last)
return false; return false;
@ -212,7 +212,7 @@ bool feed(const char *format, ...) {
va_list ap; va_list ap;
va_start(ap, format); va_start(ap, format);
feed(format, ap); feed_ap(format, ap);
va_end(ap); va_end(ap);
return true; return true;
} }

View File

@ -42,7 +42,7 @@ void setlevel(loglevel level);
bool output(const loglevel priority, const char *format, va_list ap); bool output(const loglevel priority, const char *format, va_list ap);
bool __printf_args(2, 3) bool __printf_args(2, 3)
output(const loglevel priority, const char *format, ...); output(const loglevel priority, const char *format, ...);
bool feed(const char *format, va_list ap); bool feed_ap(const char *format, va_list ap);
bool __printf_args(1, 2) feed(const char *format, ...); bool __printf_args(1, 2) feed(const char *format, ...);
class local_suffix { class local_suffix {