diff --git a/Shorewall6/lib.cli b/Shorewall6/lib.cli index 86f0edad1..ea2d8032b 100644 --- a/Shorewall6/lib.cli +++ b/Shorewall6/lib.cli @@ -158,9 +158,13 @@ show_tc() { fi } - ip -o link list | while read inx interface details; do - show_one_tc ${interface%:} - done + if [ $# -gt 0 ]; then + show_one_tc $1 + else + ip -o link list | while read inx interface details; do + show_one_tc ${interface%:} + done + fi } @@ -450,7 +454,7 @@ show_command() { packet_log 20 ;; tc) - [ $# -gt 1 ] && usage 1 + [ $# -gt 2 ] && usage 1 echo "$PRODUCT $version Traffic Control at $HOSTNAME - $(date)" echo show_tc