]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Use stdout to print information about signing
authorOndřej Surý <ondrej@sury.org>
Sun, 21 Jul 2019 11:36:13 +0000 (07:36 -0400)
committerOndřej Surý <ondrej@sury.org>
Wed, 31 Jul 2019 08:05:51 +0000 (10:05 +0200)
Previously, the default output from the libdns library went to stderr by
default.  This was inconsistent with the rest of the output.  This commit
changes the default logging to go to stdout, with notable exception - when the
output of the signing process goes to stdout, the messages are printed to the
stderr.  This is consistent with other functions that output information about
the signing process - e.g. print_stats().

bin/dnssec/dnssec-signzone.c

index c440e8f10c2206f9da98184231e96fa7d38f29a2..6a030ca594ca51f6c98761282cd6cc6b8ece8552 100644 (file)
@@ -2645,11 +2645,12 @@ loadexplicitkeys(char *keyfiles[], int n, bool setksk) {
 
 static void
 report(const char *format, ...) {
+       FILE *out = output_stdout ? stderr : stdout;
        va_list args;
        va_start(args, format);
-       vfprintf(stderr, format, args);
+       vfprintf(out, format, args);
        va_end(args);
-       putc('\n', stderr);
+       putc('\n', out);
 }
 
 static void