diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2017-12-19 18:58:06 +0100 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2017-12-19 18:58:06 +0100 |
commit | eb4bfe4621ecaa49d0b4e586315286f8e4731046 (patch) | |
tree | cb14578214805a8320576c6583a06f8ca1463113 /winsup/w32api/lib/d3dxof.def | |
parent | d5abcdd5a7fc3e45f4b0d20b7661c746e1091a8d (diff) |
cygwin: block devices: fix file offset after short writesnewlib-snapshot-20171222
When reading/writing block devices, Cygwin emulates Linux, providing
a byte-exact file position, albeit the underlying device drivers don't.
Unfortunately this only worked correctly for reading. The raw_write
method failed to revalidate the buffer after the read-modify-write
cycle in case len is not a multiple of the sector length. This in
turn resulted in lseek reporting a wrong file pointer.
Also, fix a condition for invalidating the buffer after writing from
a remaining read buffer.
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'winsup/w32api/lib/d3dxof.def')
0 files changed, 0 insertions, 0 deletions