When descending a shadow chain of objects, it makes no sense to update
the current offset (spelled: "fs.pindex") until it is known whether a backing object exists. In fact, if not for the fact that the backing object offset is zero when there is no backing object, this update would produce a broken offset. Reviewed by: kib
This commit is contained in:
parent
e9fe9edde7
commit
6753423ccb
@ -705,7 +705,6 @@ vnode_locked:
|
||||
* Move on to the next object. Lock the next object before
|
||||
* unlocking the current one.
|
||||
*/
|
||||
fs.pindex += OFF_TO_IDX(fs.object->backing_object_offset);
|
||||
next_object = fs.object->backing_object;
|
||||
if (next_object == NULL) {
|
||||
/*
|
||||
@ -743,6 +742,8 @@ vnode_locked:
|
||||
vm_object_pip_add(next_object, 1);
|
||||
if (fs.object != fs.first_object)
|
||||
vm_object_pip_wakeup(fs.object);
|
||||
fs.pindex +=
|
||||
OFF_TO_IDX(fs.object->backing_object_offset);
|
||||
VM_OBJECT_WUNLOCK(fs.object);
|
||||
fs.object = next_object;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user