From: Colm MacCarthaigh Date: Tue, 23 Aug 2005 17:03:01 +0000 (+0000) Subject: Add APR_FOPEN_BINARY to the options passed to apr for opening the X-Git-Tag: 2.3.0~3101 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=275c89cda8596738aba6d94022927199b40a2736;p=apache Add APR_FOPEN_BINARY to the options passed to apr for opening the cache header files. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@239436 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/support/htcacheclean.c b/support/htcacheclean.c index 15fd29bf1d..bfdba1c997 100644 --- a/support/htcacheclean.c +++ b/support/htcacheclean.c @@ -449,8 +449,8 @@ static int process_dir(char *path, apr_pool_t *pool) case HEADERDATA: nextpath = apr_pstrcat(p, path, "/", d->basename, CACHE_HEADER_SUFFIX, NULL); - if (apr_file_open(&fd, nextpath, APR_READ, APR_OS_DEFAULT, - p) == APR_SUCCESS) { + if (apr_file_open(&fd, nextpath, APR_FOPEN_READ | APR_FOPEN_BINARY, + APR_OS_DEFAULT, p) == APR_SUCCESS) { len = sizeof(format); if (apr_file_read_full(fd, &format, len, &len) == APR_SUCCESS) { @@ -522,8 +522,8 @@ static int process_dir(char *path, apr_pool_t *pool) current = apr_time_now(); nextpath = apr_pstrcat(p, path, "/", d->basename, CACHE_HEADER_SUFFIX, NULL); - if (apr_file_open(&fd, nextpath, APR_READ, APR_OS_DEFAULT, - p) == APR_SUCCESS) { + if (apr_file_open(&fd, nextpath, APR_FOPEN_READ | APR_FOPEN_BINARY, + APR_OS_DEFAULT, p) == APR_SUCCESS) { len = sizeof(format); if (apr_file_read_full(fd, &format, len, &len) == APR_SUCCESS) {