X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=src%2Fsrc%2Fparse.c;h=4b0efa0e1367ff6b0de3783bc9de84500e7d786e;hb=c0fb53b74e07fd17247960c998ffcb1f3c9f931f;hp=74817454e5252c13765a6b87dd1077f892ceba10;hpb=db57e575c97e06b0f0765f958073864b1729d085;p=exim.git diff --git a/src/src/parse.c b/src/src/parse.c index 74817454e..4b0efa0e1 100644 --- a/src/src/parse.c +++ b/src/src/parse.c @@ -2,7 +2,7 @@ * Exim - an Internet mail transport agent * *************************************************/ -/* Copyright (c) University of Cambridge 1995 - 2017 */ +/* Copyright (c) University of Cambridge 1995 - 2018 */ /* See the file NOTICE for conditions of use and distribution. */ /* Functions for parsing addresses */ @@ -658,7 +658,7 @@ if (*s != '@' && *s != '<') end of string will produce a null local_part and therefore fail. We don't need to keep updating t, as the phrase isn't to be kept. */ - while (*s != '<' && (!parse_allow_group || *s != ':')) + while (*s != '<' && (!f.parse_allow_group || *s != ':')) { s = read_local_part(s, t, errorptr, FALSE); if (*errorptr) @@ -670,8 +670,8 @@ if (*s != '@' && *s != '<') if (*s == ':') { - parse_found_group = TRUE; - parse_allow_group = FALSE; + f.parse_found_group = TRUE; + f.parse_allow_group = FALSE; s++; goto RESTART; } @@ -790,10 +790,10 @@ move it back past white space if necessary. */ PARSE_SUCCEEDED: if (*s != 0) { - if (parse_found_group && *s == ';') + if (f.parse_found_group && *s == ';') { - parse_found_group = FALSE; - parse_allow_group = TRUE; + f.parse_found_group = FALSE; + f.parse_allow_group = TRUE; } else { @@ -824,10 +824,10 @@ We might have an empty address in a group - the caller can choose to ignore this. We must, however, keep the flags correct. */ PARSE_FAILED: -if (parse_found_group && *s == ';') +if (f.parse_found_group && *s == ';') { - parse_found_group = FALSE; - parse_allow_group = TRUE; + f.parse_found_group = FALSE; + f.parse_allow_group = TRUE; } return NULL; } @@ -876,7 +876,7 @@ int hlen; BOOL coded = FALSE; BOOL first_byte = FALSE; -if (charset == NULL) charset = US"iso-8859-1"; +if (!charset) charset = US"iso-8859-1"; /* We don't expect this to fail! */ @@ -925,7 +925,7 @@ for (; len > 0; len--) *t++ = '='; *t = 0; -return coded? buffer : string; +return coded ? buffer : string; } @@ -2149,7 +2149,7 @@ allow_utf8_domains = FALSE; printf("Testing parse_extract_address with group syntax\n"); -parse_allow_group = TRUE; +f.parse_allow_group = TRUE; while (Ufgets(buffer, sizeof(buffer), stdin) != NULL) { uschar *out;