Page MenuHomeFreeBSD

D60280.1795631328.diff
No OneTemporary

Authored By
Unknown
Size
504 B
Referenced Files
None
Subscribers
None

D60280.1795631328.diff

diff --git a/sys/kern/uipc_shm.c b/sys/kern/uipc_shm.c
--- a/sys/kern/uipc_shm.c
+++ b/sys/kern/uipc_shm.c
@@ -246,8 +246,14 @@
found:
error = uiomove_fromphys(&m, offset, tlen, uio);
- if (uio->uio_rw == UIO_WRITE && error == 0)
+ if (uio->uio_rw == UIO_WRITE) {
+ /*
+ * Even a failed copy may have changed the page's contents,
+ * because uiomove_fromphys() can copy part of the data before
+ * it fails.
+ */
vm_page_set_dirty(m);
+ }
vm_page_activate(m);
vm_page_sunbusy(m);

File Metadata

Mime Type
text/plain
Expires
Wed, Nov 25, 6:28 PM (12 h, 4 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
40337298
Default Alt Text
D60280.1795631328.diff (504 B)

Event Timeline