[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/master] Merge branch 'ticket28856_v2'



commit f9a7701ff1228b7f1c58b4a2c9716b705cb0d126
Merge: ae578981b 29254812a
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Wed Jan 9 08:46:40 2019 -0500

    Merge branch 'ticket28856_v2'

 src/feature/dirparse/parsecommon.c | 21 ++++++++++++++++-----
 src/lib/string/util_string.c       | 15 ---------------
 src/lib/string/util_string.h       |  1 -
 src/test/test_util.c               |  9 ---------
 4 files changed, 16 insertions(+), 30 deletions(-)

diff --cc src/feature/dirparse/parsecommon.c
index b53b0fe19,a69957e74..88df5eec6
--- a/src/feature/dirparse/parsecommon.c
+++ b/src/feature/dirparse/parsecommon.c
@@@ -351,8 -363,9 +362,8 @@@ get_next_token(memarea_t *area
    if (!eol || eol-*s<11 || strcmpstart(*s, "-----BEGIN ")) /* No object. */
      goto check_object;
  
 -  obstart = *s; /* Set obstart to start of object spec */
    if (eol - *s <= 16 || memchr(*s+11,'\0',eol-*s-16) || /* no short lines, */
-       strcmp_len(eol-5, "-----", 5) ||           /* nuls or invalid endings */
+       !mem_eq_token(eol-5, 5, "-----") ||   /* nuls or invalid endings */
        (eol-*s) > MAX_UNPARSED_OBJECT_SIZE) {     /* name too long */
      RET_ERR("Malformed object: bad begin line");
    }



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits