OSSP CVS Repository

ossp - Difference in ossp-pkg/lmtp2nntp/lmtp2nntp_main.c versions 1.24 and 1.25
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [History

ossp-pkg/lmtp2nntp/lmtp2nntp_main.c 1.24 -> 1.25

--- lmtp2nntp_main.c     2002/01/31 15:13:16     1.24
+++ lmtp2nntp_main.c     2002/01/31 15:32:51     1.25
@@ -355,14 +355,8 @@
     lmtp2nntp_t  *ctx = NULL;
     int           bOk;
     int           i;             /* general purpose scratch int, index ... */
-    char         *cp;            /* general purpose character pointer */
-    char         *azTimeout;
-    size_t        asTimeout;
     pid_t         pid;
     FILE         *fd;
-    char         *cpName;
-    char         *cpValue;
-    int           nValue;
     struct passwd *sPasswd;
 
     /* drop effective uid/gid priviledges */
@@ -450,52 +444,6 @@
     /* read in the arguments */
     while ((i = getopt(argc, argv, "C:DKP:Va:b:c:d:g:h:l:m:n:o:r:s:t:u:v")) != -1) {
         switch (i) {
-            case 't': /*POD [B<-t> I<name>=I<sec>[,I<name>=I<sec>[,...]] */
-                if (argz_create_sep(optarg, ',', &azTimeout, &asTimeout) != 0)
-                    CU(ERR_EXECUTION);
-                cp = NULL;
-                while ((cp = argz_next(azTimeout, asTimeout, cp)) != NULL) {
-                    cpName = strdup(cp);
-                    if ((cpValue = strrchr(cpName, '=')) == NULL) {
-                        fprintf(stderr, "%s:Error: comma-seperated argument %s to option -t have to be name=value.\n", ctx->progname, cp);
-                        CU(ERR_EXECUTION);
-                    }
-                    *cpValue++ = NUL;
-                    nValue = atoi(cpValue);
-                    if (nValue < 0) {
-                        fprintf(stderr, "%s:Error: timeout %s=%d to option -t must be a positive integer.\n", ctx->progname, cpName, nValue);
-                        CU(ERR_EXECUTION);
-                    }
-                    if (strcmp(cpName, "lmtp") == 0) {
-                        ctx->option_timeout_lmtp_accept = nValue;
-                        ctx->option_timeout_lmtp_read = nValue;
-                        ctx->option_timeout_lmtp_write = nValue;
-                    }
-                    else if (strcmp(cpName, "lmtp:accept") == 0)
-                        ctx->option_timeout_lmtp_accept = nValue;
-                    else if (strcmp(cpName, "lmtp:read") == 0)
-                        ctx->option_timeout_lmtp_read = nValue;
-                    else if (strcmp(cpName, "lmtp:write") == 0)
-                        ctx->option_timeout_lmtp_write = nValue;
-                    else if (strcmp(cpName, "nntp") == 0) {
-                        ctx->option_timeout_nntp_connect = nValue;
-                        ctx->option_timeout_nntp_read = nValue;
-                        ctx->option_timeout_nntp_write = nValue;
-                    }
-                    else if (strcmp(cpName, "nntp:connect") == 0)
-                        ctx->option_timeout_nntp_connect = nValue;
-                    else if (strcmp(cpName, "nntp:read") == 0)
-                        ctx->option_timeout_nntp_read = nValue;
-                    else if (strcmp(cpName, "nntp:write") == 0)
-                        ctx->option_timeout_nntp_write = nValue;
-                    else {
-                        fprintf(stderr, "%s:Error: unknown timeout %s to option -t.\n", ctx->progname, cpName);
-                        CU(ERR_EXECUTION);
-                    }
-                    free(cpName);
-                }
-                free(azTimeout);
-                break;
             case 'u': /*POD [B<-u> I<uid>] */
                 if (isdigit((int)optarg[0])) {
                     if ((sPasswd = getpwuid((uid_t)atoi(optarg))) == NULL) {

CVSTrac 2.0.1