OSSP CVS Repository

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

ossp-pkg/lmtp2nntp/lmtp2nntp_option.c 1.18 -> 1.19

--- lmtp2nntp_option.c   2002/04/18 13:31:27     1.18
+++ lmtp2nntp_option.c   2002/05/29 12:24:49     1.19
@@ -508,7 +508,7 @@
                                 cpNew[0]=NUL;
                                 strcat(cpNew, "--");
                                 strcat(cpNew, option);
-                                if ((argv = (char **)realloc(argv, (argc + 1) * sizeof(char **))) == NULL)
+                                if ((argv = (char **)realloc(argv, (argc + 1 + 1) * sizeof(char **))) == NULL)
                                     return OPTION_ERR_MEM;
                                 argv[argc++] = cpNew;
                                 argv[argc] = NULL;
@@ -520,7 +520,7 @@
                                     //printf("DEBUG:     value = ***%s***\n", value);
                                     if ((cpNew = strdup(value)) == NULL)
                                         return OPTION_ERR_MEM;
-                                    if ((argv = (char **)realloc(argv, (argc + 1) * sizeof(char **))) == NULL)
+                                    if ((argv = (char **)realloc(argv, (argc + 1 + 1) * sizeof(char **))) == NULL)
                                         return OPTION_ERR_MEM;
                                     argv[argc++] = cpNew;
                                     argv[argc] = NULL;

CVSTrac 2.0.1