map_object.c (50610) | map_object.c (85004) |
---|---|
1/*- 2 * Copyright 1996-1998 John D. Polstra. 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 --- 8 unchanged lines hidden (view full) --- 17 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 18 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 * | 1/*- 2 * Copyright 1996-1998 John D. Polstra. 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 --- 8 unchanged lines hidden (view full) --- 17 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 18 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 * |
25 * $FreeBSD: head/libexec/rtld-elf/map_object.c 50610 1999-08-30 01:54:13Z jdp $ | 25 * $FreeBSD: head/libexec/rtld-elf/map_object.c 85004 2001-10-15 18:48:42Z dfr $ |
26 */ 27 28#include <sys/param.h> 29#include <sys/mman.h> 30#include <sys/stat.h> 31 32#include <errno.h> 33#include <stddef.h> 34#include <stdlib.h> 35#include <string.h> 36#include <unistd.h> 37 | 26 */ 27 28#include <sys/param.h> 29#include <sys/mman.h> 30#include <sys/stat.h> 31 32#include <errno.h> 33#include <stddef.h> 34#include <stdlib.h> 35#include <string.h> 36#include <unistd.h> 37 |
38#include "debug.h" |
|
38#include "rtld.h" 39 40static int protflags(int); /* Elf flags -> mmap protection */ 41 42/* 43 * Map a shared object into memory. The "fd" argument is a file descriptor, 44 * which must be open on the object and positioned at its beginning. 45 * The "path" argument is a pathname that is used only for error messages. --- 264 unchanged lines hidden --- | 39#include "rtld.h" 40 41static int protflags(int); /* Elf flags -> mmap protection */ 42 43/* 44 * Map a shared object into memory. The "fd" argument is a file descriptor, 45 * which must be open on the object and positioned at its beginning. 46 * The "path" argument is a pathname that is used only for error messages. --- 264 unchanged lines hidden --- |