summaryrefslogtreecommitdiff
path: root/recipes/corosync/files/fix-define-semun-union.patch
blob: 7ce5ab6733e7187712d2ad04f61fad192958be69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
diff -rupN corosync-1.2.7/lib/coroipcc.c corosync-1.2.7.new/lib/coroipcc.c
--- corosync-1.2.7/lib/coroipcc.c	2010-07-22 03:13:42.000000000 +0400
+++ corosync-1.2.7.new/lib/coroipcc.c	2010-08-03 12:06:36.000000000 +0400
@@ -68,6 +68,18 @@
 #include <semaphore.h>
 #else
 #include <sys/sem.h>
+
+#if _SEM_SEMUN_UNDEFINED
+   union semun
+   {
+     int val;                           // value for SETVAL
+     struct semid_ds *buf;              // buffer for IPC_STAT & IPC_SET
+     unsigned short int *array;         // array for GETALL & SETALL
+     struct seminfo *__buf;             // buffer for IPC_INFO
+   };
+
+#endif
+
 #endif
 
 #include "util.h"