summaryrefslogtreecommitdiff
path: root/mmap/unix/common.c
diff options
context:
space:
mode:
authordreid <dreid@13f79535-47bb-0310-9956-ffa450edef68>1999-11-13 00:07:23 +0000
committerdreid <dreid@13f79535-47bb-0310-9956-ffa450edef68>1999-11-13 00:07:23 +0000
commit1e0be6a5da06e052d1dd6fc8af53d751367a2353 (patch)
tree2a522fa0d1a59a2f3c0fe6f5f7a4b1954578a013 /mmap/unix/common.c
parent7f058f6632911234fdb110e112467baafe827bd6 (diff)
downloadlibapr-1e0be6a5da06e052d1dd6fc8af53d751367a2353.tar.gz
hange the way that we test for the size of ssize_t, using code suggested by
Ralf after I found that the test failed on FreeBSD. Update the mmap code to use a much simpler API than previously. I'll add documentation as well as support for this in http_core.c over the weekend. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@59473 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'mmap/unix/common.c')
-rw-r--r--mmap/unix/common.c30
1 files changed, 1 insertions, 29 deletions
diff --git a/mmap/unix/common.c b/mmap/unix/common.c
index 012d8c0b2..39e73d4aa 100644
--- a/mmap/unix/common.c
+++ b/mmap/unix/common.c
@@ -87,35 +87,7 @@
#if HAVE_MMAP
-ap_int32_t ap_mmap_inode_compare(const void *m1, const void *m2)
-{
- const ap_mmap_t *a = *(ap_mmap_t **)m1;
- const ap_mmap_t *b = *(ap_mmap_t **)m2;
- ap_int32_t c;
-
- if (a->statted == 0 || b->statted == 0) {
- /* we can't do this as we have no stat info... */
- /* what do we return??? */
- return (-1);
- }
- c = a->sinfo.st_ino - b->sinfo.st_ino;
- if (c == 0) {
- return a->sinfo.st_dev - b->sinfo.st_dev;
- }
- return c;
-}
-
-ap_int32_t ap_mmap_filename_compare(const void *m1, const void *m2)
-{
- const ap_mmap_t *a = m1;
- const ap_mmap_t *b = m2;
-
- return strcmp(a->filename, b->filename);
-}
-
-
-
-ap_status_t ap_mmap_offset(void **addr, ap_mmap_t *mmap, ap_size_t offset)
+ap_status_t ap_mmap_offset(void **addr, ap_mmap_t *mmap, ap_off_t offset)
{
if (offset < 0 || offset > mmap->size)
return APR_EINVAL;