summaryrefslogtreecommitdiffstats
path: root/crypto/http
diff options
context:
space:
mode:
authorDr. David von Oheimb <David.von.Oheimb@siemens.com>2020-09-16 13:29:05 +0200
committerDr. David von Oheimb <David.von.Oheimb@siemens.com>2020-09-17 15:29:46 +0200
commitbde4aa8dc1946dff189c89396814a98d1052262d (patch)
tree8c75b1f2a9a001627fe907130e8d017f0b5df22e /crypto/http
parentebcae87f6b62ed9b79a1255dbb3c69c635cea4d8 (diff)
Fix Coverity CID 1466708 - correct pointer calculation in one case
Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/12894)
Diffstat (limited to 'crypto/http')
-rw-r--r--crypto/http/http_lib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/http/http_lib.c b/crypto/http/http_lib.c
index 19b964e613..be790bda90 100644
--- a/crypto/http/http_lib.c
+++ b/crypto/http/http_lib.c
@@ -89,7 +89,7 @@ int OSSL_HTTP_parse_url(const char *url, char **phost, char **pport,
if (pport_num == NULL) {
p = strchr(port, '/');
if (p == NULL)
- p = p + strlen(port);
+ p = host_end + 1 + strlen(port);
} else { /* make sure a numerical port value is given */
portnum = strtol(port, &p, 10);
if (p == port || (*p != '\0' && *p != '/'))