mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-14 05:53:59 +00:00
108fe574a0
The read.fish check has a test where it limits the amount of data passed to `read` to 8192 bytes, and verifies that fish reads exactly that amount. This check occasionally fails on the OBS builds; it's very hard to repro a failure locally, but I finally did it. The amount of data written is limited via `yes` and `dd`: yes $line | dd bs=1024 count=(math "$fish_read_limit / 1024") The bug is that `dd` outputs a fixed number of "blocks" where a block corresponds to a single read. As `yes` and `dd` are running concurrently, it may happen that `dd` performs a short read; this then counts as a single block. So `dd` may output less than the desired amount of data. This can be verified by removing the 2>/dev/null redirection; on a successful run dd reports `8+0 records out`, on a failed run it reports `7+1 records out` because one of the records was short. Fix this by using `fullblock` so that dd will no longer count a short read as a single block. `head` would probably be a simpler tool to use but we'll do this for now. Happily it's not a fish bug. No need to relnote it. |
||
---|---|---|
.. | ||
checks | ||
pexpects | ||
test_functions | ||
.gitignore | ||
history_sample_bash | ||
history_sample_corrupt1 | ||
history_sample_fish_1_x | ||
history_sample_fish_2_0 | ||
interactive.config | ||
interactive.fish | ||
test.fish | ||
test_driver.sh | ||
test_env.sh | ||
test_util.fish |