use symlink_level_max rather than hardcoding 10; comment
This commit is contained in:
parent
eb00e40bab
commit
7e8649f8c7
@ -58,10 +58,10 @@ bind_dirs() {
|
|||||||
local symlink_level_counter
|
local symlink_level_counter
|
||||||
symlink_level_counter="0"
|
symlink_level_counter="0"
|
||||||
|
|
||||||
## For more discussion and symlink and other special files, see:
|
|
||||||
## https://phabricator.whonix.org/T414
|
|
||||||
while true; do
|
while true; do
|
||||||
if [ -h "$fso_ro" ]; then
|
if [ -h "$fso_ro" ]; then
|
||||||
|
## Resolving where there symlink points to, and using the result
|
||||||
|
## for bind mount instead.
|
||||||
symlink_level_counter="$(( symlink_level_counter + 1 ))"
|
symlink_level_counter="$(( symlink_level_counter + 1 ))"
|
||||||
true "$fso_ro is a symlink"
|
true "$fso_ro is a symlink"
|
||||||
fso_real_location="$(realpath "$fso_ro")"
|
fso_real_location="$(realpath "$fso_ro")"
|
||||||
@ -70,7 +70,7 @@ bind_dirs() {
|
|||||||
true "$fso_ro is not a symlink"
|
true "$fso_ro is not a symlink"
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
if [ "$symlink_level_counter" -ge "10" ]; then
|
if [ "$symlink_level_counter" -ge "$symlink_level_max" ]; then
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user