Commit b7fd9220 authored by Ryan Bloom's avatar Ryan Bloom
Browse files

We never use MMAP_SEGMENT_SIZE, and we are better off determining if we

have MMAP, by just checking with APR, instead of using an Apache
definition which doesn't really control anything anymore.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87563 13f79535-47bb-0310-9956-ffa450edef68
parent e66fb251
Loading
Loading
Loading
Loading
+2 −16
Original line number Diff line number Diff line
@@ -2975,21 +2975,7 @@ AP_DECLARE(apr_status_t) ap_send_fd(apr_file_t *fd, request_rec *r, apr_off_t of
    return rv;
}

#ifdef AP_USE_MMAP_FILES

/* The code writes MMAP_SEGMENT_SIZE bytes at a time.  This is due to Apache's
 * timeout model, which is a timeout per-write rather than a time for the
 * entire transaction to complete.  Essentially this should be small enough
 * so that in one Timeout period, your slowest clients should be reasonably
 * able to receive this many bytes.
 *
 * To take advantage of zero-copy TCP under Solaris 2.6 this should be a
 * multiple of 16k.  (And you need a SunATM2.0 network card.)
 */
#ifndef MMAP_SEGMENT_SIZE
#define MMAP_SEGMENT_SIZE       32768
#endif

#if APR_HAS_MMAP
/* send data from an in-memory buffer */
AP_DECLARE(size_t) ap_send_mmap(apr_mmap_t *mm, request_rec *r, size_t offset,
                             size_t length)
@@ -3004,7 +2990,7 @@ AP_DECLARE(size_t) ap_send_mmap(apr_mmap_t *mm, request_rec *r, size_t offset,

    return mm->size; /* XXX - change API to report apr_status_t? */
}
#endif /* AP_USE_MMAP_FILES */
#endif /* APR_HAS_MMAP */

AP_DECLARE(int) ap_rputc(int c, request_rec *r)
{