mirror of
https://gitlab.com/shorewall/code.git
synced 2024-12-23 22:58:52 +01:00
Fix 'truncate: command not found'; Delete redundant sub-function; more scaffolding for new Compiler
git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@5503 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
parent
892244d316
commit
8d961daed4
@ -998,12 +998,6 @@ setup_tc() {
|
||||
#
|
||||
delete_tc()
|
||||
{
|
||||
clear_one_tc() {
|
||||
save_command "tc qdisc del dev $1 root 2> /dev/null"
|
||||
save_command "tc qdisc del dev $1 ingress 2> /dev/null"
|
||||
|
||||
}
|
||||
|
||||
save_progress_message "Clearing Traffic Control/QOS"
|
||||
|
||||
append_file tcclear
|
||||
|
@ -339,6 +339,11 @@ lib_load() # $1 = Name of the Library, $2 = Error Message heading if the library
|
||||
eval loaded=\$LIB_${1}_LOADED
|
||||
|
||||
if [ -z "$loaded" ]; then
|
||||
if [ -n "$EXPERIMENTAL" ]; then
|
||||
eval LIB_${1}_LOADED=Yes
|
||||
return
|
||||
fi
|
||||
|
||||
if [ -f $lib ]; then
|
||||
progress_message "Loading library $lib..."
|
||||
. $lib
|
||||
@ -1228,6 +1233,16 @@ disable_ipv6() {
|
||||
fi
|
||||
}
|
||||
|
||||
# Function to truncate a string -- It uses 'cut -b -<n>'
|
||||
# rather than ${v:first:last} because light-weight shells like ash and
|
||||
# dash do not support that form of expansion.
|
||||
#
|
||||
|
||||
truncate() # $1 = length
|
||||
{
|
||||
cut -b -${1}
|
||||
}
|
||||
|
||||
#
|
||||
# Add a logging rule.
|
||||
#
|
||||
|
@ -128,16 +128,6 @@ is_policy_chain() # $1 = name of chain
|
||||
eval test \"\$${1}_is_policy\" = Yes
|
||||
}
|
||||
|
||||
# Function to truncate a string -- It uses 'cut -b -<n>'
|
||||
# rather than ${v:first:last} because light-weight shells like ash and
|
||||
# dash do not support that form of expansion.
|
||||
#
|
||||
|
||||
truncate() # $1 = length
|
||||
{
|
||||
cut -b -${1}
|
||||
}
|
||||
|
||||
#
|
||||
# Return a space separated list of values matching
|
||||
#
|
||||
@ -2179,6 +2169,7 @@ do_initialize() {
|
||||
report_capabilities1 > $TMP_DIR/capabilities
|
||||
export TMP_DIR
|
||||
export CONFIG_PATH
|
||||
export VERSION
|
||||
fi
|
||||
fi
|
||||
#
|
||||
|
Loading…
Reference in New Issue
Block a user