diff options
Diffstat (limited to 'utils')
-rw-r--r-- | utils/nsurl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/utils/nsurl.c b/utils/nsurl.c index 306f442b6..2133f3911 100644 --- a/utils/nsurl.c +++ b/utils/nsurl.c @@ -854,7 +854,7 @@ static nserror nsurl__create_from_section(const char const *url_s, sec_start = norm_start + colon - pegs->at + skip; if (url->scheme != NULL && length - - (colon - pegs->at + 1) == 2 && + (colon - pegs->at + skip) == 2 && *sec_start == '8' && *(sec_start + 1) == '0' && strncmp(lwc_string_data( @@ -865,7 +865,7 @@ static nserror nsurl__create_from_section(const char const *url_s, flags |= NSURL_F_NO_PORT; } - if (length - (colon - pegs->at + 1) <= 0) { + if (length - (colon - pegs->at + skip) <= 0) { /* No space for a port after the colon */ flags |= NSURL_F_NO_PORT; |