[haiku-commits] r41755 - haiku/branches/developer/bonefish/signals/headers/posix

  • From: ingo_weinhold@xxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Thu, 26 May 2011 01:36:06 +0200 (CEST)

Author: bonefish
Date: 2011-05-26 01:36:06 +0200 (Thu, 26 May 2011)
New Revision: 41755
Changeset: https://dev.haiku-os.org/changeset/41755

Modified:
   haiku/branches/developer/bonefish/signals/headers/posix/signal.h
Log:
Added sigevent structure and corresponding macro definitions.


Modified: haiku/branches/developer/bonefish/signals/headers/posix/signal.h
===================================================================
--- haiku/branches/developer/bonefish/signals/headers/posix/signal.h    
2011-05-25 23:19:15 UTC (rev 41754)
+++ haiku/branches/developer/bonefish/signals/headers/posix/signal.h    
2011-05-25 23:36:06 UTC (rev 41755)
@@ -20,11 +20,29 @@
                                                                                
           processing */
 #define SIG_HOLD       ((__sighandler_t)3)             /* the signal was hold 
*/
 
+/* macros specifying the event notification type (sigevent::sigev_notify) */
+#define SIGEV_NONE             0       /* no notification */
+#define SIGEV_SIGNAL   1       /* notify via queued signal */
+#define SIGEV_THREAD   2       /* notify via function called in new thread */
+
+
 union sigval {
        int             sival_int;
        void*   sival_ptr;
 };
 
+struct sigevent {
+       int                             sigev_notify;   /* notification type */
+       int                             sigev_signo;    /* signal number */
+       union sigval    sigev_value;    /* user-defined signal value */
+       void                    (*sigev_notify_function)(union sigval);
+                                                                       /* 
notification function in case of
+                                                                          
SIGEV_THREAD */
+       pthread_attr_t* sigev_notify_attributes;
+                                                                       /* 
pthread creation attributes in case of
+                                                                          
SIGEV_THREAD */
+};
+
 typedef struct __siginfo_t {
        int                             si_signo;       /* signal number */
        int                             si_code;        /* signal code */


Other related posts:

  • » [haiku-commits] r41755 - haiku/branches/developer/bonefish/signals/headers/posix - ingo_weinhold