svn commit: r233921 - stable/9/libexec/rtld-elf
Konstantin Belousov
kib at FreeBSD.org
Thu Apr 5 10:36:35 UTC 2012
Author: kib
Date: Thu Apr 5 10:36:35 2012
New Revision: 233921
URL: http://svn.freebsd.org/changeset/base/233921
Log:
MFC r233306:
Remove the fragments which are not needed on FreeBSD.
Modified:
stable/9/libexec/rtld-elf/malloc.c
Directory Properties:
stable/9/libexec/rtld-elf/ (props changed)
Modified: stable/9/libexec/rtld-elf/malloc.c
==============================================================================
--- stable/9/libexec/rtld-elf/malloc.c Thu Apr 5 10:33:39 2012 (r233920)
+++ stable/9/libexec/rtld-elf/malloc.c Thu Apr 5 10:36:35 2012 (r233921)
@@ -59,15 +59,6 @@ static char *rcsid = "$FreeBSD$";
#include <sys/param.h>
#include <sys/mman.h>
#include "rtld_printf.h"
-#ifndef BSD
-#define MAP_COPY MAP_PRIVATE
-#define MAP_FILE 0
-#define MAP_ANON 0
-#endif
-
-#ifndef BSD /* Need do better than this */
-#define NEED_DEV_ZERO 1
-#endif
static void morecore();
static int findbucket();
@@ -492,12 +483,6 @@ int n;
int fd = -1;
int offset;
-#ifdef NEED_DEV_ZERO
- fd = open(_PATH_DEVZERO, O_RDWR, 0);
- if (fd == -1)
- perror(_PATH_DEVZERO);
-#endif
-
if (pagepool_end - pagepool_start > pagesz) {
caddr_t addr = (caddr_t)
(((long)pagepool_start + pagesz - 1) & ~(pagesz - 1));
@@ -517,8 +502,5 @@ int n;
pagepool_end = pagepool_start + n * pagesz;
pagepool_start += offset;
-#ifdef NEED_DEV_ZERO
- close(fd);
-#endif
return n;
}
More information about the svn-src-stable-9
mailing list