Lines 41-52
Link Here
|
41 |
{ |
41 |
{ |
42 |
apr_status_t rv = APR_SUCCESS; |
42 |
apr_status_t rv = APR_SUCCESS; |
43 |
apr_shm_t *m = shm; |
43 |
apr_shm_t *m = shm; |
44 |
|
44 |
|
45 |
if (!UnmapViewOfFile(m->memblk)) { |
45 |
if (m->memblk) { |
|
|
46 |
if (!UnmapViewOfFile(m->memblk)) { |
46 |
rv = apr_get_os_error(); |
47 |
rv = apr_get_os_error(); |
|
|
48 |
} |
49 |
m->memblk = NULL; |
47 |
} |
50 |
} |
48 |
if (!CloseHandle(m->hMap)) { |
51 |
|
49 |
rv = rv != APR_SUCCESS ? rv : apr_get_os_error(); |
52 |
if (m->hMap) { |
|
|
53 |
if (!CloseHandle(m->hMap)) { |
54 |
rv = rv != APR_SUCCESS ? rv : apr_get_os_error(); |
55 |
} |
56 |
m->hMap = NULL; |
50 |
} |
57 |
} |
51 |
if (m->filename) { |
58 |
if (m->filename) { |
52 |
/* Remove file if file backed */ |
59 |
/* Remove file if file backed */ |