mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-22 06:15:58 +00:00
fix(native): creating a private SysV segment also collects stale ones
This commit is contained in:
1 parent
04f93dbe5b
commit
626c2b6568
1 file changed
+1
-1
@@ -336,7 +336,7 @@ int shmget(key_t key, size_t size, int shmflg) {
|
||||
return -1;
|
||||
}
|
||||
if (shm_ensure_dir() != 0) return -1;
|
||||
if (shmflg & IPC_CREAT) shm_collect();
|
||||
if ((shmflg & IPC_CREAT) || key == IPC_PRIVATE) shm_collect();
|
||||
if (key == IPC_PRIVATE) {
|
||||
if (size == 0) {
|
||||
errno = EINVAL;
|
||||
|
||||
Reference in new issue
Block a user