Adding a check to verify that the path to execute
is a file only and not a directory.
Pull request: https://github.com/vmware/open-vm-tools/pull/689
Jan Engelhardt Fix build problems with grpc (at least) 1.54
- https://github.com/vmware/open-vm-tools/pull/664
+
+Yun Zheng Hu Power Ops: Attempt to execute file path only
+ - https://github.com/vmware/open-vm-tools/pull/689
if [ -d "$scriptDir" ]; then
for scriptFile in "$scriptDir"/*; do
- if [ -x "$scriptFile" ]; then
+ if [ -f "$scriptFile" -a -x "$scriptFile" ]; then
"$scriptFile" $powerOp
exitCode=`expr $exitCode \| $?`
fi