Skip to content

Commit bae1d39

Browse files
authored
Merge pull request #80 from McSinyx/e9c-e
set -e for e9compile.sh
2 parents 5b17f53 + 7de3d69 commit bae1d39

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

e9compile.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
# You should have received a copy of the GNU General Public License
1616
# along with this program. If not, see <http://www.gnu.org/licenses/>.
1717

18+
set -e
19+
1820
if [ -t 1 ]
1921
then
2022
RED="\033[31m"
@@ -95,8 +97,7 @@ then
9597
exit 1
9698
fi
9799

98-
RELOCS=`readelf -r "$BASENAME" | head -n 10 | grep 'R_X86_64_'`
99-
if [ ! -z "$RELOCS" ]
100+
if readelf -r "$BASENAME" | head -n 10 | grep -q 'R_X86_64_'
100101
then
101102
echo >&2
102103
echo "${RED}warning${OFF}: the generated file (${YELLOW}$BASENAME${OFF}) contains relocations" >&2

0 commit comments

Comments
 (0)