родитель
071ee915ba
Коммит
d424be34a9
@ -136,10 +136,11 @@ parse_qos(const char *cp)
|
||||
return ipqos[i].value;
|
||||
}
|
||||
/* Try parsing as an integer */
|
||||
/* Max DSCP value is 2**6 - 1 */
|
||||
val = strtol(cp, &ep, 0);
|
||||
if (*cp == '\0' || *ep != '\0' || val < 0 || val > 255)
|
||||
if (*cp == '\0' || *ep != '\0' || val < 0 || val > 63)
|
||||
return -1;
|
||||
return val;
|
||||
return val << 2;
|
||||
}
|
||||
|
||||
const char *
|
||||
|
@ -354,7 +354,8 @@ i.e. 52, 064 and 0x34 all specify the same value.
|
||||
.TP
|
||||
.BR "--dscp " \fIdscp\fR
|
||||
set the IP DSCP bits. Both numeric and symbolic values are accepted. Numeric
|
||||
values can be specified in decimal, octal and hex (see --tos above).
|
||||
values can be specified in decimal, octal and hex (see --tos above). To set
|
||||
both the DSCP bits and the ECN bits, use --tos.
|
||||
.TP
|
||||
.BR -L ", " --flowlabel " \fIn\fR"
|
||||
set the IPv6 flow label (currently only supported on Linux)
|
||||
|
Загрузка…
Ссылка в новой задаче
Block a user