mirror of
https://github.com/markqvist/tncattach.git
synced 2025-07-30 12:32:25 -04:00
tncattach
- Cleaned up
This commit is contained in:
parent
8f32dc809e
commit
f6ff9a9618
18
tncattach.c
18
tncattach.c
@ -504,15 +504,15 @@ static error_t parse_opt(int key, char *arg, struct argp_state *state) {
|
||||
|
||||
long prefixLen_l = strtol(prefixPart_s, NULL, 10); // TODO: Add handling here for errors (using errno)
|
||||
|
||||
if(prefixLen_l == 0) {
|
||||
printf("Prefix length '%s' is not numeric\n", prefixPart_s);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
else if(!(prefixLen_l >= 0 && prefixLen_l <= 128))
|
||||
{
|
||||
printf("Prefix length '%s' is not within valid range of 0-128\n", prefixPart_s);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
if(prefixLen_l == 0) {
|
||||
printf("Prefix length '%s' is not numeric\n", prefixPart_s);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
else if(!(prefixLen_l >= 0 && prefixLen_l <= 128))
|
||||
{
|
||||
printf("Prefix length '%s' is not within valid range of 0-128\n", prefixPart_s);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
arguments->ipv6 = ipPart_s;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user