summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Chapman <matty@samba.org>1999-03-23 14:56:25 +0000
committerMatthew Chapman <matty@samba.org>1999-03-23 14:56:25 +0000
commitf7f718911b28ab5d57221ea5b3d26b202ef218e4 (patch)
tree93c0a66e0d4d6e143d77a0f689284df1121973a9
parent3fa7f643f2862f2b4660e09daae0481c1cf772ab (diff)
downloadsamba-f7f718911b28ab5d57221ea5b3d26b202ef218e4.tar.gz
samba-f7f718911b28ab5d57221ea5b3d26b202ef218e4.tar.bz2
samba-f7f718911b28ab5d57221ea5b3d26b202ef218e4.zip
Same infinite loop bug as I fixed in SAMBA_2_0, but I just spent half
an hour tracking it down in HEAD so I'm going to commit it here as well. (This used to be commit 9a482aedb2c4eb7439e2edc092642d315d2a595b)
-rw-r--r--source3/lib/util_str.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source3/lib/util_str.c b/source3/lib/util_str.c
index 31dc9bfd62..142f0af4c8 100644
--- a/source3/lib/util_str.c
+++ b/source3/lib/util_str.c
@@ -882,16 +882,16 @@ size_t strhex_to_str(char *p, size_t len, const char *strhex)
continue;
}
- while (!(p1 = strchr(hexchars, toupper(strhex[i]))))
+ if (!(p1 = strchr(hexchars, toupper(strhex[i]))))
{
- continue;
+ break;
}
i++; /* next hex digit */
- while (!(p2 = strchr(hexchars, toupper(strhex[i]))))
+ if (!(p2 = strchr(hexchars, toupper(strhex[i]))))
{
- continue;
+ break;
}
/* get the two nybbles */