Skip to content

Commit

Permalink
Remove -p calls from shasum. (#24036)
Browse files Browse the repository at this point in the history
Summary:
Fixes #22873. Given that this code is meant to only work on macOS, we should be fine not using a portable hash. In the packages for which this matters at the bottom of this file, it produces the same hashes so it should be fine.

[General] [Fixed] - Don't use `-p` when invoking shasum.
Pull Request resolved: #24036

Differential Revision: D14521134

Pulled By: cpojer

fbshipit-source-id: 882e762b7817d9d46bdd405c9e2e9e8b4d7cfaf4
  • Loading branch information
cpojer authored and facebook-github-bot committed Mar 19, 2019
1 parent 7e37370 commit 156e483
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/ios-install-third-party.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ function fetch_and_unpack () {

while true; do
if [ -f "$cachedir/$file" ]; then
if shasum -p "$cachedir/$file" |
if shasum "$cachedir/$file" |
awk -v hash="$hash" '{exit $1 != hash}'; then
break
else
echo "Incorrect hash:" 2>&1
shasum -p "$cachedir/$file" 2>&1
shasum "$cachedir/$file" 2>&1
echo "Retrying..." 2>&1
fi
fi
Expand Down

0 comments on commit 156e483

Please sign in to comment.