ipc: fix undefined behavior in no-shconf mode