Fix potential crash when shm_open fails
Misc