summaryrefslogtreecommitdiff
path: root/src/script.c
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2012-12-21 15:55:00 +0100
committerSteven Barth <steven@midlink.org>2012-12-21 15:55:00 +0100
commit28cb28d09593f9195dc29d208da0658ef8c582b6 (patch)
tree334ebd9b82132b8f81c09fdf245964d46c7f00a3 /src/script.c
parent6bdec649886d077620f4b3004782dee662f90c14 (diff)
downloadodhcp6c-28cb28d09593f9195dc29d208da0658ef8c582b6.tar.gz
Add a missing cast for some platforms
Diffstat (limited to 'src/script.c')
-rw-r--r--src/script.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/script.c b/src/script.c
index ff81278..66a15a7 100644
--- a/src/script.c
+++ b/src/script.c
@@ -58,7 +58,8 @@ ssize_t script_unhexlify(uint8_t *dst, size_t len, const char *src)
|| y < 0 || (y = hexvals[y]) < 0)
return -1;
dst[c] = x << 4 | y;
- while (*src < 0 || (*src && hexvals[(uint8_t)*src] < 0))
+ while (((int8_t)*src) < 0 ||
+ (*src && hexvals[(uint8_t)*src] < 0))
src++;
}