fix unbalance of va_start/va_end

This commit is contained in:
Yves Rutschle 2023-05-13 22:51:04 +02:00
parent db4ae0ef9d
commit d29c9524bd

6
log.c
View File

@ -107,10 +107,12 @@ void print_message(msg_info info, const char* str, ...)
{
va_list ap;
va_start(ap, str);
if ((*info.verbose & MSG_STDOUT) && ! cfg.inetd)
if ((*info.verbose & MSG_STDOUT) && ! cfg.inetd) {
va_start(ap, str);
vfprintf(stderr, str, ap);
va_end(ap);
}
if (*info.verbose & MSG_SYSLOG) {
va_start(ap, str);