IPC: remove the rekeying optimization for System V semaphores
It's hard to maintain it with multiple backends and I don't see the need for it. Change-Id: I12a088d1ae424825abd3fffd171d7bf6bbdf9a99 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>bb10
parent
b330f212a9
commit
bdaf3c458c
|
|
@ -186,15 +186,6 @@ void QSystemSemaphore::setNativeKey(const QNativeIpcKey &key, int initialValue,
|
|||
}
|
||||
|
||||
d->clearError();
|
||||
#if !defined(Q_OS_WIN) && !defined(QT_POSIX_IPC)
|
||||
// optimization to not destroy/create the file & semaphore
|
||||
if (key == d->nativeKey && mode == Create && d->backend.createdSemaphore && d->backend.createdFile) {
|
||||
d->initialValue = initialValue;
|
||||
d->backend.unix_key = -1;
|
||||
d->handle(mode);
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
d->cleanHandle();
|
||||
d->nativeKey = key;
|
||||
d->initialValue = initialValue;
|
||||
|
|
|
|||
Loading…
Reference in New Issue