Max search depth should be 1

Signed-off-by: Sebastiaan Meijer <sebastiaan@passthroughpo.st>
master
Sebastiaan Meijer 7 years ago
parent f31b9f34ad
commit e969bc084f

@ -18,9 +18,11 @@ BASEDIR="$(dirname $0)"
HOOKPATH="$BASEDIR/qemu.d/$GUEST_NAME/$HOOK_NAME/$STATE_NAME"
set -e # If a script exits with an error, we should as well.
if [ -f "$HOOKPATH" ]; then
eval "$HOOKPATH" "$@"
elif [ -d "$HOOKPATH" ]; then
find -L "$HOOKPATH" -type f -executable -exec {} "$@" \;
find -L "$HOOKPATH" -maxdepth 1 -type f -executable -exec {} "$@" \;
fi

Loading…
Cancel
Save