diff options
author | glitsj16 <glitsj16@users.noreply.github.com> | 2024-08-07 02:56:46 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-07 02:56:46 +0000 |
commit | 5d68062f12fdcd7ee61a98ad74b6c366c491d1c5 (patch) | |
tree | 9cbeb180c37d43b691a691e8e6a98deafc4b92a1 | |
parent | profiles: blacklist sway IPC socket (#6429) (diff) | |
download | firejail-5d68062f12fdcd7ee61a98ad74b6c366c491d1c5.tar.gz firejail-5d68062f12fdcd7ee61a98ad74b6c366c491d1c5.tar.zst firejail-5d68062f12fdcd7ee61a98ad74b6c366c491d1c5.zip |
feature: fshaper.sh: support tc on NixOS (#6431)
Fixes #6426.
-rwxr-xr-x | src/fshaper/fshaper.sh | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/fshaper/fshaper.sh b/src/fshaper/fshaper.sh index cd2bf79bf..16a2485bf 100755 --- a/src/fshaper/fshaper.sh +++ b/src/fshaper/fshaper.sh | |||
@@ -3,13 +3,9 @@ | |||
3 | # Copyright (C) 2014-2024 Firejail Authors | 3 | # Copyright (C) 2014-2024 Firejail Authors |
4 | # License GPL v2 | 4 | # License GPL v2 |
5 | 5 | ||
6 | TCFILE="" | 6 | TCFILE="$(PATH=/usr/sbin:/sbin:/run/current-system/sw/bin command -v tc)" |
7 | if [ -x "/usr/sbin/tc" ]; then | 7 | if [ -z "$TCFILE" ]; then |
8 | TCFILE="/usr/sbin/tc" | 8 | echo "Error: traffic control utility (tc) not found" |
9 | elif [ -x "/sbin/tc" ]; then | ||
10 | TCFILE="/sbin/tc"; | ||
11 | else | ||
12 | echo "Error: traffic control utility (tc) not found"; | ||
13 | exit 1 | 9 | exit 1 |
14 | fi | 10 | fi |
15 | 11 | ||