Skip to content

Commit

Permalink
Correctly propagate subshell failures in rustup-init
Browse files Browse the repository at this point in the history
  • Loading branch information
SabrinaJewson committed Jun 19, 2022
1 parent 20ed5d9 commit e5748eb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions rustup-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,9 @@ main() {

local _dir
_dir="$(ensure mktemp -d)"
# Because the previous command ran in a subshell, we must manually propagate
# exit status.
[ $? -ne 0 ] && exit 1
local _file="${_dir}/rustup-init${_ext}"

local _ansi_escapes_are_valid=false
Expand Down

0 comments on commit e5748eb

Please sign in to comment.