ndc's help
Paul Vixie
vixie at mibh.net
Sat Jul 29 06:16:25 UTC 2000
cricket at acmebw.com ("Cricket Liu") writes:
> Should the help command be augmented to include start and restart?
It does if you're in signal mode, which is apparently the only thing I tested.
Index: CHANGES
===================================================================
RCS file: /proj/cvs/isc/bind/src/CHANGES,v
retrieving revision 8.648
diff -u -r8.648 CHANGES
--- CHANGES 2000/07/24 17:15:40 8.648
+++ CHANGES 2000/07/29 06:14:11
@@ -1,3 +1,6 @@
+1035. [bug] ndc's "help" command worked in signal but not channel
+ mode.
+
1034. [bug] loc_ntoa() failed to correctly print altitudes in the
range [-0.99 .. -0.01].
Index: bin/ndc/ndc.c
===================================================================
RCS file: /proj/cvs/isc/bind/src/bin/ndc/ndc.c,v
retrieving revision 1.14
diff -u -r1.14 ndc.c
--- bin/ndc/ndc.c 2000/02/04 08:28:32 1.14
+++ bin/ndc/ndc.c 2000/07/29 06:09:58
@@ -296,8 +296,20 @@
static void
builtinhelp(void) {
- printf(helpfmt, "start", "start the server");
- printf(helpfmt, "restart", "stop server if any, start a new one");
+ const char *fmt;
+
+ switch (mode) {
+ case e_channel:
+ fmt = "(builtin) %s - %s\n";
+ break;
+ case e_signals:
+ fmt = helpfmt;
+ break;
+ default:
+ abort();
+ }
+ printf(fmt, "start", "start the server");
+ printf(fmt, "restart", "stop server if any, start a new one");
}
static void
@@ -371,8 +383,10 @@
int helping = (strcasecmp(cmd, "help") == 0);
int save_quiet = quiet;
- if (helping)
+ if (helping) {
quiet = 0;
+ builtinhelp();
+ }
channel_loop(cmd, !quiet, NULL, NULL);
quiet = save_quiet;
}
More information about the bind-workers
mailing list