Eli Mesika has posted comments on this change.
Change subject: tools : taskcleaner.sh utility returns always 0 as return code
......................................................................
Patch Set 2: (1 inline comment)
....................................................
File backend/manager/tools/dbutils/taskcleaner.sh
Line 105: }
Line 106:
Line 107: # Install taskcleaner procedures
Line 108: psql -U ${USERNAME} -h ${SERVERNAME} -p ${PORT} -f
./taskcleaner_sp.sql ${DATABASE} > /dev/null
Line 109: status =`echo $?`
Try this
1) create a file test.sh
2) content:
cd $1
result=$?
if [ ${result} -eq 0 ] ;then
echo OK
else
echo FAILED
fi
3) Here are the result of calling it with legal and illegal dir
> ./test.sh ~
OK
> ./test.sh /baba
./test.sh: line 1: cd: /baba: No such file or directory
FAILED
Line 110: if [$status -ne 0]; then
Line 111: exit $status
Line 112: fi
Line 113:
--
To view, visit http://gerrit.ovirt.org/12103
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: If0c61616e0c4962ee141baba7eda40341d4f721b
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Ravi Nori <[email protected]>
Gerrit-Reviewer: Eli Mesika <[email protected]>
Gerrit-Reviewer: Ravi Nori <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches