summaryrefslogtreecommitdiffstats
path: root/redhat/build/get_specfile.sh
diff options
context:
space:
mode:
Diffstat (limited to 'redhat/build/get_specfile.sh')
-rwxr-xr-xredhat/build/get_specfile.sh12
1 files changed, 7 insertions, 5 deletions
diff --git a/redhat/build/get_specfile.sh b/redhat/build/get_specfile.sh
index b7336ffcc..92fbd7ddb 100755
--- a/redhat/build/get_specfile.sh
+++ b/redhat/build/get_specfile.sh
@@ -25,10 +25,12 @@ for filename in \
"trinity-${PKGNAME}.spec" \
; do
SPECFILE="$(find "${DIST_PACKAGING_DIR}" -follow -name "${filename}")"
- if [ -r "${SPECFILE}" ]; then
- echo "${SPECFILE}"
- exit 0
- fi
+ [ -r "${SPECFILE}" ] && break || continue
done
-exit 1
+if [ -r "${SPECFILE}" ]; then
+ echo "${SPECFILE}"
+ exit 0
+else
+ exit 1
+fi