mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-01 15:05:23 +00:00
The greeting and stats were printed in some cases when +short was used.
This commit is contained in:
@@ -15,7 +15,7 @@
|
|||||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* $Id: dig.c,v 1.149 2001/07/01 23:47:49 bwelling Exp $ */
|
/* $Id: dig.c,v 1.150 2001/07/18 21:03:54 bwelling Exp $ */
|
||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
@@ -219,7 +219,7 @@ received(int bytes, isc_sockaddr_t *from, dig_query_t *query) {
|
|||||||
result = isc_time_now(&now);
|
result = isc_time_now(&now);
|
||||||
check_result(result, "isc_time_now");
|
check_result(result, "isc_time_now");
|
||||||
|
|
||||||
if (query->lookup->stats) {
|
if (query->lookup->stats && !short_form) {
|
||||||
diff = isc_time_microdiff(&now, &query->time_sent);
|
diff = isc_time_microdiff(&now, &query->time_sent);
|
||||||
printf(";; Query time: %ld msec\n", (long int)diff/1000);
|
printf(";; Query time: %ld msec\n", (long int)diff/1000);
|
||||||
printf(";; SERVER: %s(%s)\n", fromtext, query->servname);
|
printf(";; SERVER: %s(%s)\n", fromtext, query->servname);
|
||||||
@@ -364,7 +364,8 @@ printmessage(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers) {
|
|||||||
style = &dns_master_style_debug;
|
style = &dns_master_style_debug;
|
||||||
|
|
||||||
if (query->lookup->cmdline[0] != 0) {
|
if (query->lookup->cmdline[0] != 0) {
|
||||||
fputs(query->lookup->cmdline, stdout);
|
if (!short_form)
|
||||||
|
fputs(query->lookup->cmdline, stdout);
|
||||||
query->lookup->cmdline[0]=0;
|
query->lookup->cmdline[0]=0;
|
||||||
}
|
}
|
||||||
debug("printmessage(%s %s %s)", headers ? "headers" : "noheaders",
|
debug("printmessage(%s %s %s)", headers ? "headers" : "noheaders",
|
||||||
|
Reference in New Issue
Block a user