From a56cd565fee485cda2225e3a4dfd879e8e1969d1 Mon Sep 17 00:00:00 2001 From: trawick Date: Mon, 21 Mar 2011 17:04:17 +0000 Subject: merge trunk revs 1083169, 1083177, 1083178, 1083183, and 1083227 to resolve some gcc warnings and dead code on Windows (the testlfsabi change from r1083183 is omitted, as the testcases aren't in this branch) git-svn-id: http://svn.apache.org/repos/asf/apr/apr/branches/1.4.x@1083870 13f79535-47bb-0310-9956-ffa450edef68 --- file_io/win32/filestat.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'file_io') diff --git a/file_io/win32/filestat.c b/file_io/win32/filestat.c index cdd507d1a..0d2225a96 100644 --- a/file_io/win32/filestat.c +++ b/file_io/win32/filestat.c @@ -97,7 +97,7 @@ static void resolve_prot(apr_finfo_t *finfo, apr_int32_t wanted, PACL dacl) * there is no reason for os_level testing here. */ if ((wanted & APR_FINFO_WPROT) && !worldid) { - SID_IDENTIFIER_AUTHORITY SIDAuth = SECURITY_WORLD_SID_AUTHORITY; + SID_IDENTIFIER_AUTHORITY SIDAuth = {SECURITY_WORLD_SID_AUTHORITY}; if (AllocateAndInitializeSid(&SIDAuth, 1, SECURITY_WORLD_RID, 0, 0, 0, 0, 0, 0, 0, &worldid)) atexit(free_world); @@ -268,7 +268,7 @@ apr_status_t more_finfo(apr_finfo_t *finfo, const void *ufile, ((wanted & APR_FINFO_PROT) ? &dacl : NULL), NULL, &pdesc); else - return APR_INCOMPLETE; + return APR_INCOMPLETE; /* should not occur */ if (rv == ERROR_SUCCESS) apr_pool_cleanup_register(finfo->pool, pdesc, free_localheap, apr_pool_cleanup_null); @@ -319,6 +319,8 @@ apr_status_t more_finfo(apr_finfo_t *finfo, const void *ufile, sizelo = GetCompressedFileSizeW((apr_wchar_t*)ufile, &sizehi); else if (whatfile == MORE_OF_FSPEC) sizelo = GetCompressedFileSizeA((char*)ufile, &sizehi); + else + return APR_EGENERAL; /* should not occur */ if (sizelo != INVALID_FILE_SIZE || GetLastError() == NO_ERROR) { #if APR_HAS_LARGE_FILES -- cgit v1.2.1