Skip to content
Commit 041c586c authored by Yamashita, Yuu's avatar Yamashita, Yuu
Browse files

Ignore everything after whitespace in the output from sha256sum (fixes #1126)

The issue has originarily reported as pyenv/pyenv#902.

Unlike sha256sum of GNU coreutils, BusyBox one doesn't print '*'
and prints extra whitespaces, when computing digest from stdin.

sha256sum (GNU coreutils 8.26)

```
% cat /sbin/init | sha256sum -b
ef753e9504ada221155b86e7e6b7b4ff2499d64e27bcd959f0542bcac589feb1 *-
```

sha256sum (BusyBox v1.26.2)

```
/ # cat /sbin/init | sha256sum -b
4cd6d1a4028772fabc9166bb52b5826aec4e91874c107fce33dc515c04cb754f  -
```

I also confirmed that md5sum behaves just similarly.
parent 86909bfd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment