[Nagios-devel] Possible misleading help message on command line

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Guest

[Nagios-devel] Possible misleading help message on command line

Post by Guest »

I think that we may remove from usage message long options when they are
not supported. Is this OK? Sounds reasonable?

-rm


--- base/nagios.c (revision 2141)
+++ base/nagios.c (working copy)
@@ -389,14 +389,25 @@
printf("\n");
printf("Options:\n");
printf("\n");
+
+#ifdef HAVE_GETOPT_H
printf(" -v, --verify-config Verify all configuration data\n");
printf(" -s, --test-scheduling Shows projected/recommended check scheduling and other\n");
printf(" diagnostic info based on the current configuration files.\n");
- /*printf(" -o, --dont-verify-objects Don't verify object relationships - USE WITH CAUTION!\n");*/
printf(" -x, --dont-verify-paths Don't check for circular object paths - USE WITH CAUTION!\n");
printf(" -p, --precache-objects Precache object configuration - use with -v or -s options\n");
printf(" -u, --use-precached-objects Use precached object config file\n");
printf(" -d, --daemon Starts Nagios in daemon mode, instead of as a foreground process\n");
+#else
+ printf(" -v Verify all configuration data\n");
+ printf(" -s Shows projected/recommended check scheduling and other\n");
+ printf(" diagnostic info based on the current configuration files.\n");
+ printf(" -x Don't check for circular object paths - USE WITH CAUTION!\n");
+ printf(" -p Precache object configuration - use with -v or -s options\n");
+ printf(" -u Use precached object config file\n");
+ printf(" -d Starts Nagios in daemon mode, instead of as a foreground process\n");
+#endif
+
printf("\n");
printf("Visit the Nagios website at http://www.nagios.org/ for bug fixes, new\n");
printf("releases, online documentation, FAQs, information on subscribing to\n");







This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
Locked