coreutils icon indicating copy to clipboard operation
coreutils copied to clipboard

tail compatibility: tail does not output end of device

Open martinkunkel2 opened this issue 6 months ago • 1 comments

With gnu coreutils, tail is able to output the end of a device, in my case '/dev/sdc'

sudo tail -c 16 /dev/sdc | hexdump
0000000 d566 3260 cee2 32e5 7ce3 50ee 49c7 81e0
0000010

uutils coreutils just exists, exit code is 0

sudo target/debug/coreutils tail -c 16 /dev/sdc

This also causes the tests/tail/end-of-device.sh test fail in gnu compatibility tests.

Related is that gnu coreutils checks access permission

tail -c 16 /dev/sdc
tail: cannot open '/dev/sdc' for reading: Permission denied

while uutils coreutils just exists, exit code is 0

target/debug/coreutils tail -c 16 /dev/sdc

martinkunkel2 avatar May 30 '25 15:05 martinkunkel2

draft PR to fix this: https://github.com/uutils/coreutils/pull/8037

martinkunkel2 avatar May 30 '25 15:05 martinkunkel2