Fix class number assignment when WIDE_TC_MARKS=Yes

This commit is contained in:
Tom Eastep 2009-11-20 12:25:15 -08:00
parent 0df84cf8b5
commit c5bb493b29
3 changed files with 15 additions and 2 deletions

View File

@ -153,7 +153,7 @@ our @deferred_rules;
#
# TCDevices Table
#
# %tcdevices { <interface> -> {in_bandwidth => <value> ,
# %tcdevices { <interface> => {in_bandwidth => <value> ,
# out_bandwidth => <value> ,
# number => <number>,
# classify => 0|1
@ -656,7 +656,7 @@ sub validate_tc_class( ) {
if ( $classnumber ) {
fatal_error "Duplicate Class NUMBER ($classnumber)" if $tcref->{$classnumber};
} else {
$classnumber = $config{WIDE_TC_MARKS} ? $tcref->{nextclass}++ : hex_value( $devnum . $markval );
$classnumber = $config{WIDE_TC_MARKS} ? $devref->{nextclass}++ : hex_value( $devnum . $markval );
fatal_error "Duplicate MARK ($mark)" if $tcref->{$classnumber};
}
}

View File

@ -23,6 +23,8 @@ Changes in Shorewall 4.4.4
11) Implement the '-l' option to the 'show' command.
12) Fix class number assignment when WIDE_TC_MARKS=Yes
Changes in Shorewall 4.4.3
1) Move Debian INITLOG initialization to /etc/default/shorewall

View File

@ -196,6 +196,17 @@ Shorewall 4.4.4
state of the provider's interface. Now, the rules are only added
when the interface is available.
4) When TC_WIDE_MARKS=Yes and class numbers are not explicitly
specified in /etc/shorewall/tcclasses, duplicate class numbers
result. A typical error message is:
ERROR: Command "tc class add dev eth3 parent 1:1 classid
1:1 htb rate 1024kbit ceil 100000kbit prio 1 quantum 1500"
Failed
Note that the class ID of the class being added is a duplicate of
the parent's class ID.
----------------------------------------------------------------------------
K N O W N P R O B L E M S R E M A I N I N G
----------------------------------------------------------------------------