Skip to content

Commit

Permalink
Fail the Coverity build if their script cannot be downloaded
Browse files Browse the repository at this point in the history
If curl encounters an error trying to download the Coverity build script
(as seems to be happening at the moment due to SSL issues), we will not
be notified since the pipe swallows the error code. This is not ideal, so
this commit updates the Travis build steps to use a slightly more contrived
construction which will get and then execute the script as independent steps.
Also, to ensure curl returns an error code even in less-severe cases (e.g. a
basic 404 "Not Found") we add the '-f' option.

Signed-off-by: Jason Gerecke <[email protected]>
Reviewed-by: Peter Hutterer <[email protected]>
  • Loading branch information
jigpu committed Mar 14, 2018
1 parent 414ee81 commit a197cc5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,5 @@ before_script:

script:
- if [[ x"$TRAVIS_EVENT_TYPE" = "xcron" ]]; then export DO_COVERITY="YES"; fi
- if [[ x"$BUILDTYPE" = "xcoverity" && x"$DO_COVERITY" = "xYES" ]]; then curl -s "$COVERITY_URL" | bash; fi
- if [[ x"$BUILDTYPE" = "xcoverity" && x"$DO_COVERITY" = "xYES" ]]; then COVERITY_SCRIPT=$(curl -fs "$COVERITY_URL") && echo "$COVERITY_SCRIPT" | bash; fi
- if [[ x"$BUILDTYPE" != "xcoverity" ]]; then make CFLAGS="$CFLAGS" && make check; fi

0 comments on commit a197cc5

Please sign in to comment.