mirror of
https://git.code.sf.net/p/ntfs-3g/ntfs-3g.git
synced 2024-11-23 18:14:24 +08:00
ntfs_attr_pwrite: fix potential corruption and crash after partial write
This commit is contained in:
parent
cb1b5b67db
commit
fd8e63faa3
@ -1390,8 +1390,9 @@ retry:
|
||||
total += written;
|
||||
count -= written;
|
||||
b = (const u8*)b + written;
|
||||
continue;
|
||||
}
|
||||
if (written == to_write)
|
||||
continue;
|
||||
/* If the syscall was interrupted, try again. */
|
||||
if (written == (s64)-1 && errno == EINTR)
|
||||
goto retry;
|
||||
|
Loading…
Reference in New Issue
Block a user