diff options
author | kib <kib@FreeBSD.org> | 2010-01-29 19:25:45 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2010-01-29 19:25:45 +0000 |
commit | baeb94977a68b60685c3ba9d15d8b1c42bb97017 (patch) | |
tree | acf263bbdbc0ff5c1cb53f5a5b2af53197c91ddd | |
parent | e93ffcfe03e4683be2bc3edc70f32439dc4ccb88 (diff) | |
download | FreeBSD-src-baeb94977a68b60685c3ba9d15d8b1c42bb97017.zip FreeBSD-src-baeb94977a68b60685c3ba9d15d8b1c42bb97017.tar.gz |
The MAP_ENTRY_NEEDS_COPY flag belongs to protoeflags, cow variable
uses different namespace.
Reported by: Jonathan Anderson <jonathan.anderson cl cam ac uk>
MFC after: 3 days
-rw-r--r-- | sys/vm/vm_map.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c index d27c3a7..3b17a30 100644 --- a/sys/vm/vm_map.c +++ b/sys/vm/vm_map.c @@ -1136,7 +1136,7 @@ vm_map_insert(vm_map_t map, vm_object_t object, vm_ooffset_t offset, ((protoeflags & MAP_ENTRY_NEEDS_COPY) || object == NULL))) { if (!(cow & MAP_ACC_CHARGED) && !swap_reserve(end - start)) return (KERN_RESOURCE_SHORTAGE); - KASSERT(object == NULL || (cow & MAP_ENTRY_NEEDS_COPY) || + KASSERT(object == NULL || (protoeflags & MAP_ENTRY_NEEDS_COPY) || object->uip == NULL, ("OVERCOMMIT: vm_map_insert o %p", object)); uip = curthread->td_ucred->cr_ruidinfo; |