linux_misc.c (567104a1485ba7e76069976c365b6938aa83fe91) | linux_misc.c (a8d43c90af5122ecff75b55fbaf6d5806674411b) |
---|---|
1/*- 2 * Copyright (c) 1994-1995 S�ren Schmidt 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 296 unchanged lines hidden (view full) --- 305 * XXX: This should use vn_open() so that it is properly authorized, 306 * and to reduce code redundancy all over the place here. 307 */ 308#ifdef MAC 309 error = mac_check_vnode_open(td->td_ucred, vp, FREAD); 310 if (error) 311 goto cleanup; 312#endif | 1/*- 2 * Copyright (c) 1994-1995 S�ren Schmidt 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 296 unchanged lines hidden (view full) --- 305 * XXX: This should use vn_open() so that it is properly authorized, 306 * and to reduce code redundancy all over the place here. 307 */ 308#ifdef MAC 309 error = mac_check_vnode_open(td->td_ucred, vp, FREAD); 310 if (error) 311 goto cleanup; 312#endif |
313 error = VOP_OPEN(vp, FREAD, td->td_ucred, td); | 313 error = VOP_OPEN(vp, FREAD, td->td_ucred, td, -1); |
314 if (error) 315 goto cleanup; 316 317 /* Pull in executable header into kernel_map */ 318 error = vm_mmap(kernel_map, (vm_offset_t *)&a_out, PAGE_SIZE, 319 VM_PROT_READ, VM_PROT_READ, 0, (caddr_t)vp, 0); 320 /* 321 * Lock no longer needed --- 994 unchanged lines hidden --- | 314 if (error) 315 goto cleanup; 316 317 /* Pull in executable header into kernel_map */ 318 error = vm_mmap(kernel_map, (vm_offset_t *)&a_out, PAGE_SIZE, 319 VM_PROT_READ, VM_PROT_READ, 0, (caddr_t)vp, 0); 320 /* 321 * Lock no longer needed --- 994 unchanged lines hidden --- |