chiark
/
gitweb
/
~mdw
/
preload-hacks
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a8be059
)
noip: Fix ACL parsing bug in port ranges.
author
Mark Wooding
<mwooding@ncipher.com>
Wed, 1 Mar 2006 00:36:31 +0000
(
00:36
+0000)
committer
Mark Wooding
<mwooding@ncipher.com>
Wed, 1 Mar 2006 00:36:31 +0000
(
00:36
+0000)
The code failed to skip past the `-' separating the parts of the port
range, so the max port always got forced to zero. Less than useful,
really.
noip.c
patch
|
blob
|
blame
|
history
diff --git
a/noip.c
b/noip.c
index 2e2f1b10e579032321457ff71b7e734651df32fb..152540d0d370739d8411eb43802ee39f993b48d7 100644
(file)
--- a/
noip.c
+++ b/
noip.c
@@
-522,7
+522,7
@@
static void parse_ports(char **pp, unsigned short *min, unsigned short *max)
NEXTNUMBER(q, del); *min = strtoul(q, 0, 0); RESCAN(del);
SKIPSPC;
if (*p == '-')
- { NEXTNUMBER(q, del); *max = strtoul(q, 0, 0); RESCAN(del); }
+ {
p++;
NEXTNUMBER(q, del); *max = strtoul(q, 0, 0); RESCAN(del); }
else
*max = *min;
}