]> granicus.if.org Git - apache/commitdiff
* modules/loggers/mod_log_config.c, server/log.c (open_error_log,
authorJoe Orton <jorton@apache.org>
Thu, 6 May 2004 10:18:07 +0000 (10:18 +0000)
committerJoe Orton <jorton@apache.org>
Thu, 6 May 2004 10:18:07 +0000 (10:18 +0000)
ap_replace_stderr_log): Use APR_LARGEFILE when opening log files, to
allow log files to exceed the 2Gb limit if necessary.

PR: 13511

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

modules/loggers/mod_log_config.c
server/log.c

index 5c025035851d9337a73c347592ed1835a99a50b2..5e0894ef513ad31fdf4545dfd16ca6ef92e93dde 100644 (file)
 module AP_MODULE_DECLARE_DATA log_config_module;
 
 
-static int xfer_flags = (APR_WRITE | APR_APPEND | APR_CREATE);
+static int xfer_flags = (APR_WRITE | APR_APPEND | APR_CREATE | APR_LARGEFILE);
 static apr_fileperms_t xfer_perms = APR_OS_DEFAULT;
 static apr_hash_t *log_hash;
 static apr_status_t ap_default_log_writer(request_rec *r,
index 278717d9d1f13299edf6004d00eb516232913914..fcef37aa643ed44bfb03262d8662fe8055edee57 100644 (file)
@@ -158,7 +158,7 @@ AP_DECLARE(apr_status_t) ap_replace_stderr_log(apr_pool_t *p,
         return APR_EBADPATH;
     }
     if ((rc = apr_file_open(&stderr_file, filename,
-                            APR_APPEND | APR_WRITE | APR_CREATE,
+                            APR_APPEND | APR_WRITE | APR_CREATE | APR_LARGEFILE,
                             APR_OS_DEFAULT, p)) != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_STARTUP, rc, NULL,
                      "%s: could not open error log file %s.",
@@ -271,7 +271,7 @@ static int open_error_log(server_rec *s, apr_pool_t *p)
             return DONE;
         }
         if ((rc = apr_file_open(&s->error_log, fname,
-                               APR_APPEND | APR_WRITE | APR_CREATE,
+                               APR_APPEND | APR_WRITE | APR_CREATE | APR_LARGEFILE,
                                APR_OS_DEFAULT, p)) != APR_SUCCESS) {
             ap_log_error(APLOG_MARK, APLOG_STARTUP, rc, NULL,
                          "%s: could not open error log file %s.",