Index: ossp-pkg/lmtp2nntp/lmtp2nntp.c RCS File: /v/ossp/cvs/ossp-pkg/lmtp2nntp/Attic/lmtp2nntp.c,v rcsdiff -q -kk '-r1.55' '-r1.56' -u '/v/ossp/cvs/ossp-pkg/lmtp2nntp/Attic/lmtp2nntp.c,v' 2>/dev/null --- lmtp2nntp.c 2001/09/12 09:58:22 1.55 +++ lmtp2nntp.c 2001/09/12 13:04:39 1.56 @@ -489,6 +489,25 @@ } free(azHosts); break; + case 'l': /*POD [B<-l> I[:I]] */ + if ((cp = strrchr(optarg, ':')) != NULL) { + *cp++ = NUL; + if (*cp == NUL) { + fprintf(stderr, "%s:Error: empty logfile to option -l\n", ctx->progname); + exit(ERR_EXECUTION); + } + else + ctx->option_logfile = strdup(cp); + } + else + ctx->option_logfile = strdup("logfile"); + + if (l2_util_s2l(optarg, strlen(optarg), ',', &ctx->option_levelmask) != L2_OK) { + fprintf(stderr, "%s:Error: invalid level \"%s\" to option -l\n", ctx->progname, optarg); + exit(ERR_EXECUTION); + } + ctx->option_levelmask = L2_LEVEL_UPTO(ctx->option_levelmask); + break; case 'm': /*POD [B<-m> I] */ ctx->option_mailfrom = strdup(optarg); /* protect ourselfs from the substitution of backreferences. @@ -518,24 +537,6 @@ fprintf(stderr, "%s:Error: maximum message size is unacceptable small.\n", ctx->progname); exit(ERR_EXECUTION); } - case 'l': /*POD [B<-l> I[:I]] */ - if ((cp = strrchr(optarg, ':')) != NULL) { - *cp++ = NUL; - if (*cp == NUL) { - fprintf(stderr, "%s:Error: empty logfile to option -l\n", ctx->progname); - exit(ERR_EXECUTION); - } - else - ctx->option_logfile = strdup(cp); - } - else - ctx->option_logfile = strdup("logfile"); - - if (l2_util_s2l(optarg, strlen(optarg), ',', &ctx->option_levelmask) != L2_OK) { - fprintf(stderr, "%s:Error: invalid level \"%s\" to option -l\n", ctx->progname, optarg); - exit(ERR_EXECUTION); - } - ctx->option_levelmask = L2_LEVEL_UPTO(ctx->option_levelmask); break; case 'v': /*POD [B<-v>] (version)*/ fprintf(stdout, "%s\n", lmtp2nntp_version.v_gnu);