src/sniffer.c: guard against null arguments to TraceSetNamedServer(), to eliminate -Werror=format-overflow= warnings from gcc.

This commit is contained in:
Daniel Pouzzner
2020-10-29 20:28:29 -05:00
parent 937a7ce8ce
commit 22bcceb2d3

View File

@@ -992,7 +992,10 @@ static void TraceSetNamedServer(const char* name,
if (TraceOn) {
fprintf(TraceFile, "\tTrying to install a new Sniffer Server with\n");
fprintf(TraceFile, "\tname: %s, server: %s, port: %d, keyFile: %s\n",
name, srv, port, keyFile);
name ? name : "",
srv ? srv : "",
port,
keyFile ? keyFile : "");
}
}