X-Git-Url: http://www.privoxy.org/gitweb/?p=privoxy.git;a=blobdiff_plain;f=list.c;h=fcafb5777b75da30055a7ff6795ea2424e7eba1d;hp=06256d583379e171750534965b173fd9109718b5;hb=823a6f149f45a67cbac988b84398c58cd70f1e67;hpb=cfc5e0bb7116ae55800cef49ef599aa7f02b0ee9 diff --git a/list.c b/list.c index 06256d58..fcafb577 100644 --- a/list.c +++ b/list.c @@ -1,4 +1,4 @@ -const char list_rcs[] = "$Id: list.c,v 1.26 2011/12/31 14:47:44 fabiankeil Exp $"; +const char list_rcs[] = "$Id: list.c,v 1.28 2012/03/09 16:23:50 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/list.c,v $ @@ -351,7 +351,7 @@ jb_err enlist_unique(struct list *the_list, const char *str, { for (cur_entry = the_list->first; cur_entry != NULL; cur_entry = cur_entry->next) { - if ( (cur_entry->str != NULL) + if ((cur_entry->str != NULL) && (0 == strncmp(str, cur_entry->str, num_significant_chars))) { /* Already there */ @@ -364,7 +364,7 @@ jb_err enlist_unique(struct list *the_list, const char *str, /* Test whole string */ for (cur_entry = the_list->first; cur_entry != NULL; cur_entry = cur_entry->next) { - if ( (cur_entry->str != NULL) && (0 == strcmp(str, cur_entry->str))) + if ((cur_entry->str != NULL) && (0 == strcmp(str, cur_entry->str))) { /* Already there */ return JB_ERR_OK; @@ -979,7 +979,7 @@ jb_err map(struct map *the_map, if ( (NULL == value) || (NULL == name) - || (NULL == (new_entry = zalloc(sizeof(*new_entry)))) ) + || (NULL == (new_entry = zalloc(sizeof(*new_entry))))) { if ((name != NULL) && (!name_needs_copying)) {