Skip to content

Commit

Permalink
fix(net): check if var is empty instead of matching strings
Browse files Browse the repository at this point in the history
  • Loading branch information
ezrizhu committed Oct 27, 2023
1 parent 7d6599e commit 2da3064
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions try
Original file line number Diff line number Diff line change
Expand Up @@ -233,10 +233,10 @@ EOF
# --pid: create a new process namespace (needed fr procfs to work right)
# --fork: necessary if we do --pid
# "Creation of a persistent PID namespace will fail if the --fork option is not also specified."
if [ "$EXTRA_NS" = "net" ]; then
unshare --mount --map-root-user --user --pid --fork --net "$mount_and_execute"
else
if [ -z "$EXTRA_NS" ]; then
unshare --mount --map-root-user --user --pid --fork "$mount_and_execute"
else
unshare --mount --map-root-user --user --pid --fork --net "$mount_and_execute"
fi
TRY_EXIT_STATUS=$?

Expand Down

0 comments on commit 2da3064

Please sign in to comment.