[dovecot-cvs] dovecot/src/lib-sql sql-api.c, 1.13, 1.14 sql-api.h, 1.10, 1.11
tss at dovecot.org
tss at dovecot.org
Fri Dec 15 16:55:45 UTC 2006
- Previous message: [dovecot-cvs] dovecot/src/lib-mail istream-header-filter.c, 1.35, 1.36 istream-header-filter.h, 1.8, 1.9 message-body-search.c, 1.28, 1.29 message-content-parser.c, 1.14, 1.15 message-content-parser.h, 1.8, 1.9 message-decoder.c, 1.4, 1.5 message-header-decode.c, 1.6, 1.7 message-header-decode.h, 1.4, 1.5 message-header-parser.c, 1.3, 1.4 message-header-parser.h, 1.2, 1.3 message-parser.c, 1.75, 1.76 message-parser.h, 1.34, 1.35
- Next message: [dovecot-cvs] dovecot/src/lib-storage mail-search.c, 1.20, 1.21 mail-search.h, 1.13, 1.14 mailbox-list.c, 1.4, 1.5 mailbox-list.h, 1.3, 1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /var/lib/cvs/dovecot/src/lib-sql
In directory talvi:/tmp/cvs-serv346/lib-sql
Modified Files:
sql-api.c sql-api.h
Log Message:
Added context parameter type safety checks for most callback APIs.
Index: sql-api.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-sql/sql-api.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- sql-api.c 10 Sep 2006 12:48:22 -0000 1.13
+++ sql-api.c 15 Dec 2006 16:55:43 -0000 1.14
@@ -76,6 +76,7 @@
db->exec(db, query);
}
+#undef sql_query
void sql_query(struct sql_db *db, const char *query,
sql_query_callback_t *callback, void *context)
{
@@ -157,6 +158,7 @@
return db->transaction_begin(db);
}
+#undef sql_transaction_commit
void sql_transaction_commit(struct sql_transaction_context **_ctx,
sql_commit_callback_t *callback, void *context)
{
Index: sql-api.h
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-sql/sql-api.h,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- sql-api.h 1 Jul 2006 17:24:11 -0000 1.10
+++ sql-api.h 15 Dec 2006 16:55:43 -0000 1.11
@@ -45,6 +45,9 @@
/* Execute SQL query and return result in callback. */
void sql_query(struct sql_db *db, const char *query,
sql_query_callback_t *callback, void *context);
+#define sql_query(db, query, callback, context) \
+ CONTEXT_CALLBACK2(sql_query, sql_query_callback_t, \
+ callback, context, db, query)
/* Execute blocking SQL query and return result. */
struct sql_result *sql_query_s(struct sql_db *db, const char *query);
@@ -80,6 +83,9 @@
/* Commit transaction. */
void sql_transaction_commit(struct sql_transaction_context **ctx,
sql_commit_callback_t *callback, void *context);
+#define sql_transaction_commit(ctx, callback, context) \
+ CONTEXT_CALLBACK2(sql_transaction_commit, sql_commit_callback_t, \
+ callback, context, ctx)
/* Synchronous commit. Returns 0 if ok, -1 if error. */
int sql_transaction_commit_s(struct sql_transaction_context **ctx,
const char **error_r);
- Previous message: [dovecot-cvs] dovecot/src/lib-mail istream-header-filter.c, 1.35, 1.36 istream-header-filter.h, 1.8, 1.9 message-body-search.c, 1.28, 1.29 message-content-parser.c, 1.14, 1.15 message-content-parser.h, 1.8, 1.9 message-decoder.c, 1.4, 1.5 message-header-decode.c, 1.6, 1.7 message-header-decode.h, 1.4, 1.5 message-header-parser.c, 1.3, 1.4 message-header-parser.h, 1.2, 1.3 message-parser.c, 1.75, 1.76 message-parser.h, 1.34, 1.35
- Next message: [dovecot-cvs] dovecot/src/lib-storage mail-search.c, 1.20, 1.21 mail-search.h, 1.13, 1.14 mailbox-list.c, 1.4, 1.5 mailbox-list.h, 1.3, 1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the dovecot-cvs
mailing list