summaryrefslogtreecommitdiff
path: root/libc/inet/resolv.c
diff options
context:
space:
mode:
Diffstat (limited to 'libc/inet/resolv.c')
-rw-r--r--libc/inet/resolv.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libc/inet/resolv.c b/libc/inet/resolv.c
index 4e82776a5..9245840ca 100644
--- a/libc/inet/resolv.c
+++ b/libc/inet/resolv.c
@@ -167,8 +167,9 @@ int decode_dotted(const unsigned char *data, int offset,
if (!data)
return -1;
- while ((measure && total++), (l=data[offset++])) {
-
+ while ((l=data[offset++])) {
+ if (measure)
+ total++;
if ((l & 0xc0) == (0xc0)) {
if (measure)
total++;