| Date: Wed, 15 Feb 2006 18:37:21 +0000
fixes
Diffstat:
M src/cmd/ndb/dnsdebug.c | 3 +--
M src/cmd/ndb/dnsquery.c | 4 ++--
M src/cmd/ndb/dnstcp.c | 12 ++++++++++--
3 files changed, 13 insertions(+), 6 deletions(-)
--- |
| t@@ -47,6 +47,7 @@ usage(void)
fprint(2, "usage: dnsdebug -rxf [-p port] [query ...]\n");
threadexitsall("usage");
}
+char *portname = "domain";
void
threadmain(int argc, char *argv[])
t@@ -323,7 +324,6 @@ squirrelserveraddrs(void)
l = &(*l)->next;
continue;
}
- req.isslave = 1;
req.aborttime = now + 60; /* don't spend more than 60 seconds */
*l = dnresolve(rp->host->name, Cin, Ta, &req, 0, 0, Recurse, 0, 0);
while(*l != nil)
t@@ -427,7 +427,6 @@ doquery(char *name, char *tstr)
}
getactivity(&req);
- req.isslave = 1;
req.aborttime = now + 60; /* don't spend more than 60 seconds */
rr = dnresolve(buf, Cin, type, &req, 0, 0, Recurse, rooted, 0);
if(rr){ |
| t@@ -3,6 +3,7 @@
#include
#include
#include
+#include <9pclient.h>
#include "dns.h"
#include "ip.h"
t@@ -14,9 +15,8 @@ usage(void)
}
void
-main(int argc, char *argv[])
+threadmain(int argc, char *argv[])
{
- char *dns;
CFid *fd;
int n, len;
Biobuf in; |
| t@@ -28,10 +28,15 @@ char *zonerefreshprogram;
char *portname = "domain";
void
-threadmain(int argc, char *argv[])
+usage(void)
{
- char *ext = "";
+ fprint(2, "usage: dnstcp [-dr] [-f dbfile]\n");
+ threadexitsall("usage");
+}
+void
+threadmain(int argc, char *argv[])
+{
ARGBEGIN{
default:
usage();
t@@ -46,6 +51,9 @@ threadmain(int argc, char *argv[])
break;
}ARGEND
+ if(argc)
+ usage();
+
if(debug < 2)
debug = 0;
|