Index: modules/slotmem/mod_slotmem_shm.c =================================================================== --- modules/slotmem/mod_slotmem_shm.c (revision 1698117) +++ modules/slotmem/mod_slotmem_shm.c (working copy) @@ -246,6 +246,7 @@ static apr_status_t cleanup_slotmem(void *param) if (AP_SLOTMEM_IS_PERSIST(next)) { store_slotmem(next); } + apr_shm_destroy((apr_shm_t *)next->shm); if (next->fbased) { const char *name; apr_shm_remove(next->name, next->gpool); @@ -254,7 +255,6 @@ static apr_status_t cleanup_slotmem(void *param) apr_file_remove(name, next->gpool); } } - apr_shm_destroy((apr_shm_t *)next->shm); next = next->next; } }