[dovecot-cvs] dovecot/src/imap client.c,1.19,1.20 client.h,1.6,1.7 cmd-list.c,1.12,1.13 commands.c,1.5,1.6 commands.h,1.5,1.6

cras at procontrol.fi cras at procontrol.fi
Sat Jan 11 21:55:58 EET 2003


Update of /home/cvs/dovecot/src/imap
In directory danu:/tmp/cvs-serv27659/imap

Modified Files:
	client.c client.h cmd-list.c commands.c commands.h 
Log Message:
Naming change for function typedefs.



Index: client.c
===================================================================
RCS file: /home/cvs/dovecot/src/imap/client.c,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -d -r1.19 -r1.20
--- client.c	5 Jan 2003 13:09:51 -0000	1.19
+++ client.c	11 Jan 2003 19:55:56 -0000	1.20
@@ -34,7 +34,8 @@
 static struct client *my_client; /* we don't need more than one currently */
 static struct timeout *to_idle;
 
-static void client_input(struct client *client);
+static void client_input(void *context, int fd __attr_unused__,
+			 struct io *io __attr_unused__);
 
 static void client_output_timeout(void *context)
 {
@@ -72,7 +73,7 @@
 	o_stream_set_blocking(client->output, CLIENT_OUTPUT_TIMEOUT,
 			      client_output_timeout, client);
 
-	client->io = io_add(hin, IO_READ, (IOFunc) client_input, client);
+	client->io = io_add(hin, IO_READ, client_input, client);
 	client->parser = imap_parser_create(client->input, client->output,
 					    MAX_INBUF_SIZE,
 					    MAX_IMAP_ARG_ELEMENTS);
@@ -301,8 +302,11 @@
 	return TRUE;
 }
 
-static void client_input(struct client *client)
+static void client_input(void *context, int fd __attr_unused__,
+			 struct io *io __attr_unused__)
 {
+	struct client *client = context;
+
 	client->last_input = ioloop_time;
 
 	switch (i_stream_read(client->input)) {

Index: client.h
===================================================================
RCS file: /home/cvs/dovecot/src/imap/client.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- client.h	5 Jan 2003 13:09:51 -0000	1.6
+++ client.h	11 Jan 2003 19:55:56 -0000	1.7
@@ -6,7 +6,7 @@
 
 struct client;
 
-typedef int (*ClientCommandFunc) (struct client *client);
+typedef int (*client_command_func_t)(struct client *client);
 
 struct client {
 	int socket;
@@ -23,7 +23,7 @@
 	struct imap_parser *parser;
 	const char *cmd_tag; /* tag of command (allocated from parser pool), */
 	const char *cmd_name; /* command name (allocated from parser pool) */
-	ClientCommandFunc cmd_func;
+	client_command_func_t cmd_func;
 
 	unsigned int cmd_error:1;
 	unsigned int cmd_uid:1; /* used UID command */

Index: cmd-list.c
===================================================================
RCS file: /home/cvs/dovecot/src/imap/cmd-list.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- cmd-list.c	5 Jan 2003 13:09:51 -0000	1.12
+++ cmd-list.c	11 Jan 2003 19:55:56 -0000	1.13
@@ -77,8 +77,8 @@
 	return *node;
 }
 
-static void list_func(struct mail_storage *storage __attr_unused__,
-		      const char *name, enum mailbox_flags flags, void *context)
+static void list_cb(struct mail_storage *storage __attr_unused__,
+		    const char *name, enum mailbox_flags flags, void *context)
 {
 	struct list_context *ctx = context;
 	struct list_node *node;
@@ -173,11 +173,11 @@
 		if (!subscribed) {
 			failed = !client->storage->
 				find_mailboxes(client->storage,
-					       pattern, list_func, &ctx);
+					       pattern, list_cb, &ctx);
 		} else {
 			failed = !client->storage->
 				find_subscribed(client->storage,
-						pattern, list_func, &ctx);
+						pattern, list_cb, &ctx);
 		}
 
 		if (!failed) {

Index: commands.c
===================================================================
RCS file: /home/cvs/dovecot/src/imap/commands.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- commands.c	8 Jan 2003 20:49:52 -0000	1.5
+++ commands.c	11 Jan 2003 19:55:56 -0000	1.6
@@ -3,7 +3,7 @@
 #include "common.h"
 #include "commands.h"
 
-ClientCommandFunc client_command_find(const char *name)
+client_command_func_t client_command_find(const char *name)
 {
 	/* keep the command uppercased */
 	name = str_ucase(t_strdup_noconst(name));

Index: commands.h
===================================================================
RCS file: /home/cvs/dovecot/src/imap/commands.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- commands.h	8 Jan 2003 20:49:52 -0000	1.5
+++ commands.h	11 Jan 2003 19:55:56 -0000	1.6
@@ -4,7 +4,7 @@
 #include "commands-util.h"
 #include "imap-parser.h"
 
-ClientCommandFunc client_command_find(const char *name);
+client_command_func_t client_command_find(const char *name);
 
 /* Non-Authenticated State */
 int cmd_authenticate(struct client *client);




More information about the dovecot-cvs mailing list