diff options
Diffstat (limited to 'tables')
-rw-r--r-- | tables/apr_tables.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tables/apr_tables.c b/tables/apr_tables.c index 45e88172b..092bb3f68 100644 --- a/tables/apr_tables.c +++ b/tables/apr_tables.c @@ -1,3 +1,4 @@ +#include <stdio.h> /* ==================================================================== * The Apache Software License, Version 1.1 * @@ -1127,8 +1128,8 @@ APR_DECLARE(void) apr_table_compress(apr_table_t *t, unsigned flags) dups_found = 0; sort_next = sort_array; sort_end = sort_array + t->a.nelts; - last = sort_next; - while (++sort_next < sort_end) { + last = sort_next++; + while (sort_next < sort_end) { if (((*sort_next)->key_checksum == (*last)->key_checksum) && !strcasecmp((*sort_next)->key, (*last)->key)) { apr_table_entry_t **dup_last = sort_next + 1; @@ -1176,7 +1177,7 @@ APR_DECLARE(void) apr_table_compress(apr_table_t *t, unsigned flags) } while (++sort_next <= dup_last); } else { - last = sort_next; + last = sort_next++; } } |