]> git.saurik.com Git - apple/xnu.git/blobdiff - bsd/kern/ubc_subr.c
xnu-2422.115.4.tar.gz
[apple/xnu.git] / bsd / kern / ubc_subr.c
index f9ae6591bdea4cce463730d31b26a289725ac1cc..2916f3e08b3546f6fc770034999b9d780cbea371 100644 (file)
@@ -1744,6 +1744,9 @@ ubc_map(vnode_t vp, int flags)
                        if ( !ISSET(uip->ui_flags, UI_ISMAPPED))
                                need_ref = 1;
                        SET(uip->ui_flags, (UI_WASMAPPED | UI_ISMAPPED));
+                       if (flags & PROT_WRITE) {
+                               SET(uip->ui_flags, UI_MAPPEDWRITE);
+                       }
                }
                CLR(uip->ui_flags, UI_MAPBUSY);