From: Felix Fietkau Date: Sat, 27 Apr 2024 18:59:43 +0000 (+0200) Subject: netifd: packet_steering: fix shell error on unset steering_flows option X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=2d6fd937c36bf3d8991b0fd9f6d845fab18af790;p=openwrt%2Fstaging%2Fneocturne.git netifd: packet_steering: fix shell error on unset steering_flows option Signed-off-by: Felix Fietkau --- diff --git a/package/network/config/netifd/files/etc/init.d/packet_steering b/package/network/config/netifd/files/etc/init.d/packet_steering index 19d423797a..5266a931ae 100755 --- a/package/network/config/netifd/files/etc/init.d/packet_steering +++ b/package/network/config/netifd/files/etc/init.d/packet_steering @@ -16,7 +16,7 @@ service_triggers() { reload_service() { packet_steering="$(uci -q get "network.@globals[0].packet_steering")" steering_flows="$(uci -q get "network.@globals[0].steering_flows")" - [ "$steering_flows" -gt 0 ] && opts="-l $steering_flows" + [ "${steering_flows:-0}" -gt 0 ] && opts="-l $steering_flows" if [ -e "/usr/libexec/platform/packet-steering.sh" ]; then /usr/libexec/platform/packet-steering.sh "$packet_steering" else