X-Git-Url: https://git.distorted.org.uk/~mdw/adns/blobdiff_plain/a93e4dbf7b9638742ca0d9d8864f33885128f3c9..09aee00b1873954d4a767e0590f32b9774253d9f:/client/adnsresfilter.c diff --git a/client/adnsresfilter.c b/client/adnsresfilter.c index 6891d88..bba1b1c 100644 --- a/client/adnsresfilter.c +++ b/client/adnsresfilter.c @@ -4,10 +4,10 @@ */ /* * This file is - * Copyright (C) 1999 Ian Jackson + * Copyright (C) 1999-2000 Ian Jackson * * It is part of adns, which is - * Copyright (C) 1997-1999 Ian Jackson + * Copyright (C) 1997-2000 Ian Jackson * Copyright (C) 1999 Tony Finch * * This program is free software; you can redistribute it and/or modify @@ -33,10 +33,12 @@ #include #include -#include +#include +#include +#include -#include "adns.h" #include "config.h" +#include "adns.h" #include "dlist.h" #include "tvarith.h" @@ -50,7 +52,7 @@ struct outqueuenode { }; static int bracket, forever, address; -static unsigned long timeout=100; +static unsigned long timeout= 1000; static adns_rrtype rrt= adns_r_ptr; static int outblocked, inputeof; @@ -109,11 +111,13 @@ static void outputerr(void) { sysfail("write to stdout"); } static void usage(void) { if (printf("usage: adnsresfilter []\n" " adnsresfilter -h|--help\n" - "options: -b|--brackets\n" - " -w|--wait\n" - " -t|--timeout \n" - " -a|--address (always include address in output)\n" - " -u|--unchecked\n") + "options: -t|--timeout \n" + " -w|--wait (always wait for queries to time out or fail)\n" + " -b|--brackets (require [...] around IP addresses)\n" + " -a|--address (always include [address] in output)\n" + " -u|--unchecked (do not forward map for checking)\n" + "Timeout is the maximum amount to delay any particular bit of output for.\n" + "Lookups will go on in the background. Default timeout = 100 (ms).\n") == EOF) outputerr(); } @@ -367,7 +371,6 @@ static void readstdin(void) { if (!bracket && !isalnum(c)) startaddr(); } } - if (cbyte==3 && inbyte>0 && !bracket) procaddr(); } static void startup(void) {