]> granicus.if.org Git - apache/commitdiff
a long time ago ...
authorAndré Malo <nd@apache.org>
Mon, 28 Jul 2003 14:18:45 +0000 (14:18 +0000)
committerAndré Malo <nd@apache.org>
Mon, 28 Jul 2003 14:18:45 +0000 (14:18 +0000)
REWRITELOCK_MODE wasn't used anymore for ages. In the meantime it defined
the mode of the rewritelog (sic!) file. So fix the misnaming and
use constants for mode and open flags.

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

modules/mappers/mod_rewrite.c

index a594773798ff8baa7e5eea53c8b0b76548957d6f..bf0d578f0f079ec346a3001bbfbad27b0a3da2cb 100644 (file)
 /* default maximum number of internal redirects */
 #define REWRITE_REDIRECT_LIMIT 10
 
-/* for rewrite lock file */
-#define REWRITELOCK_MODE ( APR_UREAD | APR_UWRITE | APR_GREAD | APR_WREAD )
+/* for rewrite log file */
+#define REWRITELOG_MODE  ( APR_UREAD | APR_UWRITE | APR_GREAD | APR_WREAD )
+#define REWRITELOG_FLAGS ( APR_WRITE | APR_APPEND | APR_CREATE )
 
 /* max line length (incl.\n) in text rewrite maps */
 #ifndef REWRITE_MAX_TXT_MAP_LINE
@@ -386,9 +387,6 @@ static void open_rewritelog(server_rec *s, apr_pool_t *p)
     const char *fname;
     apr_status_t rc;
     piped_log *pl;
-    int rewritelog_flags = ( APR_WRITE | APR_APPEND | APR_CREATE );
-    apr_fileperms_t rewritelog_mode = ( APR_UREAD | APR_UWRITE |
-                                        APR_GREAD | APR_WREAD );
 
     conf = ap_get_module_config(s->module_config, &rewrite_module);
 
@@ -420,7 +418,7 @@ static void open_rewritelog(server_rec *s, apr_pool_t *p)
             exit(1);
         }
         if ((rc = apr_file_open(&conf->rewritelogfp, fname,
-                                rewritelog_flags, rewritelog_mode, p))
+                                REWRITELOG_FLAGS, REWRITELOG_MODE, p))
                 != APR_SUCCESS) {
             ap_log_error(APLOG_MARK, APLOG_ERR, rc, s,
                          "mod_rewrite: could not open RewriteLog "