- Fixed warnings

- Fixed deadlock in xsi_sem_undo - RecordUndo
- Fixed issue in xsi_sem_undo: if the semaphore set does not exist
anymore, ignore the request but do remove the process from the sUndoList,
which wasn't previously done.
- free() in ClearUndos was called with interrupts disabled
- when a semaphore set ends to exist, remove all it's sem_undo request as it's ID
will be reused in the future.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26727 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Salvatore Benedetto
2008-08-02 11:30:55 +00:00
parent 64ea0b9f74
commit 51daeb7147
4 changed files with 53 additions and 44 deletions
+1 -9
View File
@@ -11,15 +11,7 @@
#include <OS.h>
#include <kernel.h>
// TODO: move into a system/posix/xsi_semaphore_defs.h file to be shared with
// xsi_sem.cpp in libroot!
union semun {
int val;
struct semid_ds *buf;
unsigned short *array;
};
#include <posix/xsi_semaphore_defs.h>
__BEGIN_DECLS
@@ -0,0 +1,18 @@
/*
* Copyright 2008, Salvatore Benedetto, [email protected].
* Distributed under the terms of the MIT License.
*/
#ifndef SYSTEM_XSI_SEM_H
#define SYSTEM_XSI_SEM_H
/*
* Shared union used by the semctl option argument.
* The user should declare it explicitly
*/
union semun {
int val;
struct semid_ds *buf;
unsigned short *array;
};
#endif