Manage memory mapped resources more robustly.