OSSP CVS Repository

ossp - Check-in [2165]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 2165
Date: 2002-May-28 14:43:14 (local)
2002-May-28 12:43:14 (UTC)
User:thl
Branch:
Comment: rename
Tickets:
Inspections:
Files:
ossp-pkg/lmtp2nntp/fixme.h      1.23 -> 1.24     1 inserted, 1 deleted
ossp-pkg/lmtp2nntp/lmtp2nntp_config.c      1.73 -> 1.74     4 inserted, 4 deleted
ossp-pkg/lmtp2nntp/lmtp2nntp_msg.c      1.22 -> 1.23     11 inserted, 11 deleted

ossp-pkg/lmtp2nntp/fixme.h 1.23 -> 1.24

--- fixme.h      2002/05/27 15:09:50     1.23
+++ fixme.h      2002/05/28 12:43:14     1.24
@@ -37,7 +37,7 @@
     headerrule_t *next;
     int           pri;
     char         *regex;
-    char         *header;
+    char         *name;
     char         *val;
     pcre         *pcreRegex;
     pcre_extra   *pcreExtra;


ossp-pkg/lmtp2nntp/lmtp2nntp_config.c 1.73 -> 1.74

--- lmtp2nntp_config.c   2002/05/27 15:09:50     1.73
+++ lmtp2nntp_config.c   2002/05/28 12:43:14     1.74
@@ -587,7 +587,7 @@
                     hrNew->next      = NULL;
                     hrNew->pri       = 500; /* default priority */
                     hrNew->regex     = NULL;
-                    hrNew->header    = NULL;
+                    hrNew->name      = NULL;
                     hrNew->val       = NULL;
                     hrNew->pcreRegex = NULL;
                     hrNew->pcreExtra = NULL;
@@ -624,7 +624,7 @@
                         logbook(ctx->l2, L2_LEVEL_ERROR, "option --headerrule, header (%s) missing", (ov->data.m)[i]);
                         throw(0,0,0);
                     }
-                    hrNew->header = str_dupex(cpP, n);
+                    hrNew->name   = str_dupex(cpP, n);
                     /* value */
                     cpP = cp;
                     n = strlen(cpP);
@@ -682,8 +682,8 @@
                     free(hrNew->pcreRegex);
                 if (hrNew->val != NULL)
                     freeex(hrNew->val);
-                if (hrNew->header != NULL)
-                    freeex(hrNew->header);
+                if (hrNew->name != NULL)
+                    freeex(hrNew->name);
                 if (hrNew->regex != NULL)
                     freeex(hrNew->regex);
                 freeex((headerrule_t *)hrNew);


ossp-pkg/lmtp2nntp/lmtp2nntp_msg.c 1.22 -> 1.23

--- lmtp2nntp_msg.c      2002/05/28 12:32:58     1.22
+++ lmtp2nntp_msg.c      2002/05/28 12:43:14     1.23
@@ -975,19 +975,19 @@
                     /* expanding regex references into header name */
                     {
                         char *res_ptr;
-                        logbook(ctx->l2, L2_LEVEL_DEBUG, "expanding regex references in headername '%s'", hrI->header);
-                        if ((var_rc = var_expand(ctx->config_varregex, hrI->header, strlen(hrI->header), &res_ptr, NULL, FALSE)) != VAR_OK) {
-                            logbook(ctx->l2, L2_LEVEL_ERROR, "expansion of '%s' failed: %s", hrI->header, var_strerror(ctx->config_varregex, var_rc, &cp) == VAR_OK ? cp : "Unknown Error", var_rc);
+                        logbook(ctx->l2, L2_LEVEL_DEBUG, "expanding regex references in headername '%s'", hrI->name);
+                        if ((var_rc = var_expand(ctx->config_varregex, hrI->name, strlen(hrI->name), &res_ptr, NULL, FALSE)) != VAR_OK) {
+                            logbook(ctx->l2, L2_LEVEL_ERROR, "expansion of '%s' failed: %s", hrI->name, var_strerror(ctx->config_varregex, var_rc, &cp) == VAR_OK ? cp : "Unknown Error", var_rc);
                         }
                         logbook(ctx->l2, L2_LEVEL_DEBUG, "expansion result '%s'", res_ptr);
                         if (strlen(res_ptr) == 0) {
                             logbook(ctx->l2, L2_LEVEL_DEBUG, "marking deleted - emtpy headername");
-                            hdNew->name = NULL; //FIXME rename ->header to ->name
+                            hdNew->name = NULL;
                             /*FIXME clean up data.s and data.m */
                             hdNew->ndata = 0;
                         }
                         else {
-                            hdNew->name = res_ptr; //FIXME rename ->header to ->name
+                            hdNew->name = res_ptr;
                         }
                     }
                     if (hrI->val == NULL) {
@@ -1034,9 +1034,9 @@
             }
         }
         else {
-            logbook(ctx->l2, L2_LEVEL_DEBUG, "rule has no regex but static header %s", hrI->header);
+            logbook(ctx->l2, L2_LEVEL_DEBUG, "rule has no regex but static header %s", hrI->name);
             hdNew = headercreate();
-            hdNew->name = strdupex(hrI->header); //FIXME rename ->header to ->name
+            hdNew->name = strdupex(hrI->name);
             if (hrI->val == NULL) {
                 logbook(ctx->l2, L2_LEVEL_DEBUG, "marking deleted");
                 /*FIXME clean up data.s and data.m */
@@ -1064,18 +1064,18 @@
             for (hdI = ctx->msg->hdFirst; hdI != NULL; hdI = hdI->next) { /* for each header */
                 if (hdI->name == NULL || strlen(hdI->name) == 0)
                     continue;
-                logbook(ctx->l2, L2_LEVEL_DEBUG, "hrI->header=%s, hdI->name=%s", hrI->header, hdI->name);
-                if (strcasecmp(hrI->header, hdI->name) == 0)
+                logbook(ctx->l2, L2_LEVEL_DEBUG, "hrI->name=%s, hdI->name=%s", hrI->name, hdI->name);
+                if (strcasecmp(hrI->name, hdI->name) == 0)
                     break;
             }
             if (hdI != NULL) {
-                logbook(ctx->l2, L2_LEVEL_DEBUG, "replacing header %s", hrI->header);
+                logbook(ctx->l2, L2_LEVEL_DEBUG, "replacing header %s", hrI->name);
                 headerreplace(hdI, hdNew);
                 if (hdNew->prev == NULL)
                     ctx->msg->hdFirst = hdNew;
             }
             else {
-                logbook(ctx->l2, L2_LEVEL_DEBUG, "appending header %s", hrI->header);
+                logbook(ctx->l2, L2_LEVEL_DEBUG, "appending header %s", hrI->name);
                 for (hdI = ctx->msg->hdFirst; hdI->next != NULL; hdI = hdI->next);
                 hdI->next = hdNew;
                 hdNew->prev = hdI;

CVSTrac 2.0.1