]> granicus.if.org Git - apache/commitdiff
when logging a failure of ap_mmap_create(), pass the returned
authorJeff Trawick <trawick@apache.org>
Wed, 29 Mar 2000 02:52:31 +0000 (02:52 +0000)
committerJeff Trawick <trawick@apache.org>
Wed, 29 Mar 2000 02:52:31 +0000 (02:52 +0000)
status to ap_log_rerror() instead of the current errno value

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

modules/http/http_core.c

index b68372e9396ea1eabd194704be6712c69a78185c..2187a84797db1669ab0a61d30e097605a240b583 100644 (file)
@@ -2552,8 +2552,9 @@ static int default_handler(request_rec *r)
        && (!r->header_only || (d->content_md5 & 1))) {
        /* we need to protect ourselves in case we die while we've got the
         * file mmapped */
-    if (ap_mmap_create(&mm, fd, 0, r->finfo.size, r->pool) != APR_SUCCESS){
-           ap_log_rerror(APLOG_MARK, APLOG_CRIT, errno, r,
+        ap_status_t status;
+        if ((status = ap_mmap_create(&mm, fd, 0, r->finfo.size, r->pool)) != APR_SUCCESS) {
+           ap_log_rerror(APLOG_MARK, APLOG_CRIT, status, r,
                         "default_handler: mmap failed: %s", r->filename);
            mm = NULL;
        }