8335b1
--- a/server/util.c  2017/05/30 12:27:41 1796855
8335b1
+++ b/server/util.c  2017/05/30 12:28:20 1796856
8335b1
@@ -1679,10 +1679,8 @@
8335b1
 
8335b1
     s = (const unsigned char *)line;
8335b1
     for (;;) {
8335b1
-        /* find start of token, skip all stop characters, note NUL
8335b1
-         * isn't a token stop, so we don't need to test for it
8335b1
-         */
8335b1
-        while (TEST_CHAR(*s, T_HTTP_TOKEN_STOP)) {
8335b1
+        /* find start of token, skip all stop characters */
8335b1
+        while (*s && TEST_CHAR(*s, T_HTTP_TOKEN_STOP)) {
8335b1
             ++s;
8335b1
         }
8335b1
         if (!*s) {