Format option ignored when reading from stdin
a free cross platform checksum utility, supports 58+ hash algorithms
Brought to you by:
jonelo
Hi,
I noticed that the format option is not respected when processing data from stdin.
Here the expected output when using -q:
$ jacksum -a "crc8" -F "#ALGONAME{i} #CHECKSUM{i}" -q txt:12345678
crc8 199
I would have expected the same output when passing data from stdin, but this is not the case:
$ echo -n "12345678" | jacksum -a "crc8" -F "#ALGONAME{i} #CHECKSUM{i}"
199 8 -
Moreover, passing multiple algorithms produce weird output.
The expected output would be the same as the -q option:
$ jacksum -a "crc8+crc32" -F "#ALGONAME{i} #CHECKSUM{i}" -q txt:12345678
crc8 c7
crc32 9ae0daaf
Instead the current behavior seems to concatenate the checksums:
$ echo -n "12345678" | jacksum -a "crc8+crc32" -F "#ALGONAME{i} #CHECKSUM{i}"
c79ae0daaf 8 -
I am using the package from Debian, I not sure if this is a problem with some modifications done by Debian or if the problem is repsoducible with the original code too.
Thanks, Antonio
P.S. Any news on 1.8.0?
Thank you Antonio for the well prepared bug report. I can reproduce the issue, and I will fix it for the next release. Please stay tuned.
Kind Regards,
Johann
fixed in Jacksum 3. See also https://github.com/jonelo/jacksum/releases/tag/v3.0.0
Thanks for your patience, Antonio.
Cheers,
Johann
Thanks Johann, you know how they say: "good things come to those who wait".
Ah, I just saw the release notes right after writing this :)
Thanks again for jacksum
Take care, Antonio