mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-08 19:33:07 +00:00
c96a9f58a2
pread only works for seekable files, so, for example, a pipe could not be used. The non-async Console uses read calls and doesn't have this issue. There is a possibility of breaking something with this change. Suppose crosvm was passed an input FD with the cursor at the end of a non-empty file. Before the async console would read the full file from the beginning, but now it would immediately EOF. Another difference is that if the device is reset and then reactivated, it will continue reading from where it left off instead of restarting at the beginning of the input. In both cases, I think the new behavior is better and additionally matches the non-async console's behavior. The async console is relatively new, so hopefully no one is depending on this part of its behavior yet. BUG=b:243198718 TEST=presubmit Change-Id: I8e07e231d5def250eb5f42e9a4546fce721cc4bc Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/3842811 Reviewed-by: Alexandre Courbot <acourbot@chromium.org> Commit-Queue: Frederick Mayle <fmayle@google.com> Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> |
||
---|---|---|
.. | ||
src | ||
Cargo.toml |