summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2003-05-29 14:46:30 +0000
committerJelmer Vernooij <jelmer@samba.org>2003-05-29 14:46:30 +0000
commitd75a4281c5a96a1e29b34b3a2f10bdb089221b77 (patch)
tree29e3239234dcf158bddacf92ecbb364563c75fc7 /source3/include
parentba06fdbf669dfa8b115b1a0fbe2bf3b7ed5f558c (diff)
downloadsamba-d75a4281c5a96a1e29b34b3a2f10bdb089221b77.tar.gz
samba-d75a4281c5a96a1e29b34b3a2f10bdb089221b77.tar.bz2
samba-d75a4281c5a96a1e29b34b3a2f10bdb089221b77.zip
Fix the events API. Patch by metze with some minor modifications.
(This used to be commit df24c4e839b3de0dc23400463d7489a991f61f49)
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/module.h20
1 files changed, 7 insertions, 13 deletions
diff --git a/source3/include/module.h b/source3/include/module.h
index 759ea5bb38..c41310c7f7 100644
--- a/source3/include/module.h
+++ b/source3/include/module.h
@@ -24,21 +24,15 @@
/* Module support */
typedef NTSTATUS (init_module_function) (void);
+
+typedef int smb_event_id_t;
+#define SMB_EVENT_ID_INVALID (-1)
+
#define SMB_IDLE_EVENT_DEFAULT_INTERVAL 180
#define SMB_IDLE_EVENT_MIN_INTERVAL 30
-typedef struct smb_idle_event_struct {
- struct smb_idle_event_struct *prev,*next;
- time_t interval;
- time_t last_run;
- void *data;
- void (*fn)(struct smb_idle_event_struct **event, time_t now);
-} smb_idle_event_struct;
-
-typedef struct smb_exit_event_struct {
- struct smb_exit_event_struct *prev,*next;
- void *data;
- void (*fn)(struct smb_exit_event_struct **event);
-} smb_exit_event_struct;
+typedef void (smb_idle_event_fn)(void **data,time_t *interval,time_t now);
+
+typedef void (smb_exit_event_fn)(void **data);
#endif /* _MODULE_H */