OSSP CVS Repository

ossp - Difference in ossp-pkg/pth/pth.h.in versions 1.137 and 1.138
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [History

ossp-pkg/pth/pth.h.in 1.137 -> 1.138

--- pth.h.in     2002/11/03 16:31:34     1.137
+++ pth.h.in     2002/11/05 19:39:09     1.138
@@ -209,6 +209,13 @@
 #define PTH_WALK_NEXT                _BIT(1)
 #define PTH_WALK_PREV                _BIT(2)
 
+    /* event status codes */
+typedef enum {
+    PTH_STATUS_PENDING,
+    PTH_STATUS_OCCURRED,
+    PTH_STATUS_FAILED
+} pth_status_t;
+
     /* the key type and init value */
 typedef int pth_key_t;
 #define PTH_KEY_INIT (-1)
@@ -447,7 +454,7 @@
 extern pth_event_t    pth_event_concat(pth_event_t, ...);
 extern pth_event_t    pth_event_isolate(pth_event_t);
 extern pth_event_t    pth_event_walk(pth_event_t, unsigned int);
-extern int            pth_event_occurred(pth_event_t);
+extern pth_status_t   pth_event_status(pth_event_t);
 extern int            pth_event_free(pth_event_t, int);
 
     /* key-based storage functions */
@@ -564,5 +571,10 @@
 #define pwrite        pth_pwrite
 #endif
 
+    /* backward compatibility (Pth < 1.5.0) */
+#define pth_event_occurred(ev) \
+    (   pth_event_status(ev) == PTH_STATUS_OCCURRED \
+     || pth_event_status(ev) == PTH_STATUS_FAILED   )
+
 #endif /* _PTH_H_ */
 

CVSTrac 2.0.1