summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
authorHiltjo Posthuma <hiltjo@codemadness.org>2019-02-27 19:19:35 +0100
committerHiltjo Posthuma <hiltjo@codemadness.org>2019-02-27 19:19:35 +0100
commitd89d948c77f55ccfa56cbfe595e6474f070d0b2d (patch)
tree721c9005d7506fa07155a8fdc205d56367bfca79 /util.c
parent13d7b7a6df950c32162dcb157123bc47e1904b07 (diff)
util: parseuri: fix typo in cast (ssize_t)
Diffstat (limited to 'util.c')
-rw-r--r--util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util.c b/util.c
index 89c2ef7..e9461ea 100644
--- a/util.c
+++ b/util.c
@@ -49,7 +49,7 @@ parseuri(const char *s, struct uri *u, int rel)
/* IPv6 address */
if (*p == '[') {
/* bracket not found or host too long */
- if (!(b = strchr(p, ']')) || (size_t)(b - p) >= (ssize_t)sizeof(u->host))
+ if (!(b = strchr(p, ']')) || (size_t)(b - p) >= sizeof(u->host))
return -1;
memcpy(u->host, p + 1, b - p - 1);
u->host[b - p - 1] = '\0';