diff options
author | Ulrich Drepper <drepper@redhat.com> | 2005-08-08 20:42:33 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2005-08-08 20:42:33 +0000 |
commit | f54a329a28050846c0475b45f8bf131f66eab996 (patch) | |
tree | afa7b9a28fcc411dd84e30dcc8bd413f4a795866 /nscd/connections.c | |
parent | e62995c1121da99a64657bb952b20d08de0b932e (diff) | |
download | glibc-f54a329a28050846c0475b45f8bf131f66eab996.tar.gz |
* nscd/mem.c (mempool_alloc): Use posix_fallocate instead of ftruncate.
* nscd/connections.c (nscd_init): Likewise.
Diffstat (limited to 'nscd/connections.c')
-rw-r--r-- | nscd/connections.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nscd/connections.c b/nscd/connections.c index 808ea33adb..7ead3fd5e7 100644 --- a/nscd/connections.c +++ b/nscd/connections.c @@ -638,7 +638,7 @@ cannot create read-only descriptor for \"%s\"; no mmap"), if ((TEMP_FAILURE_RETRY (write (fd, &head, sizeof (head))) != sizeof (head)) - || ftruncate (fd, total) != 0 + || posix_fallocate (fd, 0, total) != 0 || (mem = mmap (NULL, total, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0)) == MAP_FAILED) { |