From 9ef87c2f05ec0fe59c960c919875a483896dd3eb Mon Sep 17 00:00:00 2001 From: Jeff Trawick Date: Sat, 3 Jun 2000 14:31:34 +0000 Subject: [PATCH] mod_cgi: Make ScriptLog directive work again by fixing the flags passed to ap_open(). TODO: Roll recent mod_cgi logging changes into mod_cgid. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85392 13f79535-47bb-0310-9956-ffa450edef68 --- modules/generators/mod_cgi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/generators/mod_cgi.c b/modules/generators/mod_cgi.c index e2297f876d..c969a40c69 100644 --- a/modules/generators/mod_cgi.c +++ b/modules/generators/mod_cgi.c @@ -185,7 +185,7 @@ static int log_scripterror(request_rec *r, cgi_server_conf * conf, int ret, ((ap_stat(&finfo, ap_server_root_relative(r->pool, conf->logname), r->pool) == APR_SUCCESS) && (finfo.size > conf->logbytes)) || (ap_open(&f, ap_server_root_relative(r->pool, conf->logname), - APR_APPEND, APR_OS_DEFAULT, r->pool) != APR_SUCCESS)) { + APR_APPEND|APR_WRITE|APR_CREATE, APR_OS_DEFAULT, r->pool) != APR_SUCCESS)) { return ret; } @@ -234,7 +234,7 @@ static int log_script(request_rec *r, cgi_server_conf * conf, int ret, ((ap_stat(&finfo, ap_server_root_relative(r->pool, conf->logname), r->pool) == APR_SUCCESS) && (finfo.size > conf->logbytes)) || (ap_open(&f, ap_server_root_relative(r->pool, conf->logname), - APR_APPEND, APR_OS_DEFAULT, r->pool) != APR_SUCCESS)) { + APR_APPEND|APR_WRITE|APR_CREATE, APR_OS_DEFAULT, r->pool) != APR_SUCCESS)) { /* Soak up script output */ while (ap_bgets(argsbuffer, HUGE_STRING_LEN, script_in) > 0) continue; -- 2.40.0