commit 3e34840a77c45da3575b8a929ed8bbd7370aad63 Author: Nick Mathewson nickm@torproject.org Date: Wed Jul 3 10:27:38 2019 -0400
Make config_lines_eq() take const arguments. --- src/lib/encoding/confline.c | 2 +- src/lib/encoding/confline.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/lib/encoding/confline.c b/src/lib/encoding/confline.c index fdb575e03..0d8384db1 100644 --- a/src/lib/encoding/confline.c +++ b/src/lib/encoding/confline.c @@ -256,7 +256,7 @@ config_lines_dup_and_filter(const config_line_t *inp, /** Return true iff a and b contain identical keys and values in identical * order. */ int -config_lines_eq(config_line_t *a, config_line_t *b) +config_lines_eq(const config_line_t *a, const config_line_t *b) { while (a && b) { if (strcasecmp(a->key, b->key) || strcmp(a->value, b->value)) diff --git a/src/lib/encoding/confline.h b/src/lib/encoding/confline.h index 56ea36bf6..12c554c6e 100644 --- a/src/lib/encoding/confline.h +++ b/src/lib/encoding/confline.h @@ -50,7 +50,7 @@ const config_line_t *config_line_find(const config_line_t *lines, const char *key); const config_line_t *config_line_find_case(const config_line_t *lines, const char *key); -int config_lines_eq(config_line_t *a, config_line_t *b); +int config_lines_eq(const config_line_t *a, const config_line_t *b); int config_count_key(const config_line_t *a, const char *key); void config_free_lines_(config_line_t *front); #define config_free_lines(front) \