]> granicus.if.org Git - apache/commitdiff
This is ugly, but at least we compile again on platforms that lack
authorJim Jagielski <jim@apache.org>
Sat, 7 Oct 2000 00:37:18 +0000 (00:37 +0000)
committerJim Jagielski <jim@apache.org>
Sat, 7 Oct 2000 00:37:18 +0000 (00:37 +0000)
sendfile().
PR:
Obtained from:
Submitted by:
Reviewed by:

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86423 13f79535-47bb-0310-9956-ffa450edef68

modules/http/http_core.c

index 759901e1ddf1b4c11592066c8e2f24930f1bd10a..a6f1ffd429511e1f1ca4c42acd7dd2831db142ef 100644 (file)
@@ -3384,6 +3384,13 @@ static int core_output_filter(ap_filter_t *f, ap_bucket_brigade *b)
         }
         if (fd) {
             apr_hdtr_t hdtr;
+#if APR_HAS_SENDFILE
+/*
+ * TODO: fix the call to send_the_file somehow to remove the need for
+ * the apr_hdtr_t paramater if !APR_HAS_SENDFILE. The way it is
+ * now, we have to define a dummy apr_hdtr_t typedef and then
+ * wrap sections anyway. -- jj
+ */
             memset(&hdtr, '\0', sizeof(hdtr));
             if (nvec) {
                 hdtr.numheaders = nvec;
@@ -3393,6 +3400,7 @@ static int core_output_filter(ap_filter_t *f, ap_bucket_brigade *b)
                 hdtr.numtrailers = nvec_trailers;
                 hdtr.trailers = vec_trailers;
             }
+#endif
             rv = send_the_file(c, fd, &hdtr, foffset, flen, &bytes_sent);
         }
         else {