From 5b11d91db228b9b81287dd1dcd876190514e49d7 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Fri, 11 Dec 2020 15:33:48 +0100 Subject: [PATCH] ttcn3-tcpdump-start: Fix path of setcap if we test if /sbin/setcap exists, we als should execute it from that path, as running from a normal user doesn't have /sbin included in $PATH Change-Id: I5131f869f86e6d136e0485da5e3749abbfc951e3 --- ttcn3-tcpdump-start.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ttcn3-tcpdump-start.sh b/ttcn3-tcpdump-start.sh index 3ad14c0ae..e905d8a75 100755 --- a/ttcn3-tcpdump-start.sh +++ b/ttcn3-tcpdump-start.sh @@ -39,7 +39,7 @@ if [ -x $DUMPCAP ]; then CAP_ERR="1" if [ -x /sbin/setcap ]; then # N. B: this check requires libcap2-bin package - setcap -q -v 'cap_net_admin,cap_net_raw=pie' $DUMPCAP + /sbin/setcap -q -v 'cap_net_admin,cap_net_raw=pie' $DUMPCAP CAP_ERR="$?" fi if [ -u $DUMPCAP -o "$CAP_ERR" = "0" ]; then