summaryrefslogtreecommitdiff
path: root/source3/include/proto.h
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2000-09-12 00:47:11 +0000
committerAndrew Tridgell <tridge@samba.org>2000-09-12 00:47:11 +0000
commit06eeb3c45803bcf26ee586103a974fd852de21b9 (patch)
treef6dedcae3ebee3d75186987bb38ea315fa1ad5b9 /source3/include/proto.h
parentd836024b2816f37abd523afb3b2d4f2bfb130f0a (diff)
downloadsamba-06eeb3c45803bcf26ee586103a974fd852de21b9.tar.gz
samba-06eeb3c45803bcf26ee586103a974fd852de21b9.tar.bz2
samba-06eeb3c45803bcf26ee586103a974fd852de21b9.zip
much nicer message interface. We now register dispatch functions,
allowing new bits of code or vfs modules to register functions without impacting on the messaging code itself. Also note that multiple registrations for the same message type are possible allowing the same message to be delivered to multiple parts of the code (possibly useful for reload messages). (This used to be commit c3350c77f52cade48d2945574e09cb630af85b92)
Diffstat (limited to 'source3/include/proto.h')
-rw-r--r--source3/include/proto.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 754c51ee9d..f12f7e1570 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -59,9 +59,9 @@ uint32 crc32_calc_buffer( char *buffer, uint32 count);
/*The following definitions come from lib/debug.c */
-void debug_message(pid_t src, void *buf, int len);
+void debug_message(enum message_type msg_type, pid_t src, void *buf, size_t len);
void debug_message_send(pid_t pid, int level);
-void setup_logging( char *pname, BOOL interactive );
+void setup_logging(char *pname, BOOL interactive);
void reopen_logs( void );
void force_check_log_size( void );
BOOL need_to_check_log_size( void );
@@ -155,6 +155,8 @@ void mdfour(unsigned char *out, unsigned char *in, int n);
BOOL message_init(void);
BOOL message_send_pid(pid_t pid, enum message_type msg_type, void *buf, size_t len);
void message_dispatch(void);
+void message_register(enum message_type msg_type,
+ void (*fn)(enum message_type msg_type, pid_t pid, void *buf, size_t len));
/*The following definitions come from lib/ms_fnmatch.c */