summaryrefslogtreecommitdiffstats
path: root/modules/cache
diff options
context:
space:
mode:
Diffstat (limited to 'modules/cache')
-rw-r--r--modules/cache/mod_cache_disk.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/modules/cache/mod_cache_disk.c b/modules/cache/mod_cache_disk.c
index 52d5dba0b1..ddf16f9c03 100644
--- a/modules/cache/mod_cache_disk.c
+++ b/modules/cache/mod_cache_disk.c
@@ -994,10 +994,11 @@ static apr_status_t write_headers(cache_handle_t *h, request_rec *r)
}
rv = mkdir_structure(conf, dobj->hdrs.file, r->pool);
-
- rv = apr_file_mktemp(&dobj->vary.tempfd, dobj->vary.tempfile,
- APR_CREATE | APR_WRITE | APR_BINARY | APR_EXCL,
- dobj->vary.pool);
+ if (rv == APR_SUCCESS) {
+ rv = apr_file_mktemp(&dobj->vary.tempfd, dobj->vary.tempfile,
+ APR_CREATE | APR_WRITE | APR_BINARY | APR_EXCL,
+ dobj->vary.pool);
+ }
if (rv != APR_SUCCESS) {
ap_log_rerror(APLOG_MARK, APLOG_WARNING, rv, r, APLOGNO(00721)