docker: Fix handling of PCAP variable (fixes #8567) (#8568)

This correctly handles the absense of the PCAP environment variable,
which was broken in the previous change.
This commit is contained in:
Jakob Borg
2022-10-02 08:50:27 +02:00
committed by GitHub
parent 1e652de5af
commit a206366d10
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ set -eu
if [ "$(id -u)" = '0' ]; then
binary="$1"
if [ "$PCAP" == "" ] ; then
if [ "${PCAP:-}" == "" ] ; then
# If Syncthing should have no extra capabilities, make sure to remove them
# from the binary. This will fail with an error if there are no
# capabilities to remove, hence the || true etc.