diff options
author | Mladen Turk <mturk@apache.org> | 2021-12-02 21:21:18 +0000 |
---|---|---|
committer | Mladen Turk <mturk@apache.org> | 2021-12-02 21:21:18 +0000 |
commit | 6487330c38e3c0430782a5ceca674b94398f347f (patch) | |
tree | ededff55d7051624a164926ea86ad603d6776026 /shmem | |
parent | 2520ce23f2830c59cfc2786effbbe72903c49ad5 (diff) | |
download | apr-6487330c38e3c0430782a5ceca674b94398f347f.tar.gz |
Stage 3 in dismantling _WIN32_WCE ... cleanup code
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1895508 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'shmem')
-rw-r--r-- | shmem/win32/shm.c | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/shmem/win32/shm.c b/shmem/win32/shm.c index 0ca8247f9..48b33b8b8 100644 --- a/shmem/win32/shm.c +++ b/shmem/win32/shm.c @@ -153,9 +153,7 @@ APR_DECLARE(apr_status_t) apr_shm_create_ex(apr_shm_t **m, if (!file) { /* Do Anonymous, which must be passed as a duplicated handle */ -#ifndef _WIN32_WCE hFile = INVALID_HANDLE_VALUE; -#endif mapkey = NULL; } else { @@ -293,15 +291,7 @@ static apr_status_t shm_attach_internal(apr_shm_t **m, #if APR_HAS_UNICODE_FS IF_WIN_OS_IS_UNICODE { -#ifndef _WIN32_WCE hMap = OpenFileMappingW(FILE_MAP_READ | FILE_MAP_WRITE, FALSE, mapkey); -#else - /* The WCE 3.0 lacks OpenFileMapping. So we emulate one with - * opening the existing shmem and reading its size from the header - */ - hMap = CreateFileMappingW(INVALID_HANDLE_VALUE, NULL, - PAGE_READWRITE, 0, sizeof(apr_shm_t), mapkey); -#endif } #endif #if APR_HAS_ANSI_FS @@ -326,22 +316,6 @@ static apr_status_t shm_attach_internal(apr_shm_t **m, (*m)->memblk = base; /* Real (*m)->mem->size could be recovered with VirtualQuery */ (*m)->size = (*m)->memblk->size; -#if _WIN32_WCE - /* Reopen with real size */ - UnmapViewOfFile(base); - CloseHandle(hMap); - - hMap = CreateFileMappingW(INVALID_HANDLE_VALUE, NULL, - PAGE_READWRITE, 0, (*m)->size, mapkey); - if (!hMap) { - return apr_get_os_error(); - } - base = MapViewOfFile(hMap, FILE_MAP_READ | FILE_MAP_WRITE, 0, 0, 0); - if (!base) { - CloseHandle(hMap); - return apr_get_os_error(); - } -#endif (*m)->hMap = hMap; (*m)->length = (*m)->memblk->length; (*m)->usrmem = (char*)base + sizeof(memblock_t); |