diff options
Diffstat (limited to 'sys/compat/linux/linux_misc.c')
-rw-r--r-- | sys/compat/linux/linux_misc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/compat/linux/linux_misc.c b/sys/compat/linux/linux_misc.c index a2c9a24..16c8677 100644 --- a/sys/compat/linux/linux_misc.c +++ b/sys/compat/linux/linux_misc.c @@ -317,15 +317,15 @@ linux_uselib(struct thread *td, struct linux_uselib_args *args) if (error) goto cleanup; + /* Pull in executable header into kernel_map */ + error = vm_mmap(kernel_map, (vm_offset_t *)&a_out, PAGE_SIZE, + VM_PROT_READ, VM_PROT_READ, 0, (caddr_t)vp, 0); /* * Lock no longer needed */ - VOP_UNLOCK(vp, 0, td); locked = 0; + VOP_UNLOCK(vp, 0, td); - /* Pull in executable header into kernel_map */ - error = vm_mmap(kernel_map, (vm_offset_t *)&a_out, PAGE_SIZE, - VM_PROT_READ, VM_PROT_READ, 0, (caddr_t)vp, 0); if (error) goto cleanup; |