Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
support/download/git: properly catch failures
Since commit b7efb43 (download/git: try to recover from utterly-broken repositories), we catch errors through an ERR trap, so we can try and recover from a broken repository. In that commit, we switched from using "set -e" to "set -E", so that trap is inherited in functions, command substitutions, and subshells. However, the trap is not defined until we have parsed the options, created the cache directory, and eventually chdir()ed into it. Athough improbable, it is possible for the git helper to fail in any of those steps, and that would not get caught. Fix that Signed-off-by: Yann E. MORIN <[email protected]> Signed-off-by: Thomas Petazzoni <[email protected]>
- Loading branch information