Details
Description
ftok key collisions are especially problematic with QSystemSemaphore since the SystemV implementation of QSystemSemaphorePrivate::handle will retry semget without IPC_EXCL, which can lead to cases where an unrelated semaphore is opened.
To work around this issue we can add some more entropy to ftok via a wrapper, but unfortunately we cannot change the semantics of QSystemSemaphore directly.