Re: linux-2.4.0-test11 and sysklogd-1.3-31

From: Georg Nikodym (georgn@somanetworks.com)
Date: Mon Dec 11 2000 - 20:53:16 EST


>>>>> "KO" == Keith Owens <kaos@ocs.com.au> writes:

 KO> Looks good, except that you need to keep the option flags for
 KO> backwards compatibility. There are a *lot* of scripts out there
 KO> which invoke klogd with various options and they will fail with
 KO> this change. It is OK to issue a warning message "klogd options
 KO> -[iIpkx] are no longer supported" as long as klogd continues to
 KO> run. Otherwise you will get a lot of irate users complaining
 KO> that klogd is failing at boot time.

You're right. Here's YAP:

diff -Nru a/src/sysklogd-1.3-31/klogd.c b/src/sysklogd-1.3-31/klogd.c
--- a/src/sysklogd-1.3-31/klogd.c Mon Dec 11 20:50:49 2000
+++ b/src/sysklogd-1.3-31/klogd.c Mon Dec 11 20:50:49 2000
@@ -763,7 +763,7 @@
         chdir ("/");
 #endif
         /* Parse the command-line. */
- while ((ch = getopt(argc, argv, "c:df:nosv")) != EOF)
+ while ((ch = getopt(argc, argv, "c:df:nosviIk:px")) != EOF)
                 switch((char)ch)
                 {
                     case 'c': /* Set console message level. */
@@ -788,6 +788,20 @@
                     case 'v':
                         printf("klogd %s-%s\n", VERSION, PATCHLEVEL);
                         exit (1);
+
+ /* Obsolete options */
+ case 'i':
+ /* FALLTHRU */
+ case 'I':
+ /* FALLTHRU */
+ case 'k':
+ /* FALLTHRU */
+ case 'p':
+ /* FALLTHRU */
+ case 'x':
+ fprintf(stderr,
+ "klogd: %c option is obsolete. Ignoring\n", ch);
+ break;
                 }
 
 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Dec 15 2000 - 21:00:23 EST