[dovecot-cvs] dovecot/src/lib-dict dict.c,1.7,1.8

cras at dovecot.org cras at dovecot.org
Sun Jul 30 21:03:21 EEST 2006


Update of /var/lib/cvs/dovecot/src/lib-dict
In directory talvi:/tmp/cvs-serv24218

Modified Files:
	dict.c 
Log Message:
dict_atomic_inc(): Do nothing if diff parameter is 0.



Index: dict.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-dict/dict.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- dict.c	28 Jun 2006 13:10:34 -0000	1.7
+++ dict.c	30 Jul 2006 18:03:18 -0000	1.8
@@ -130,5 +130,6 @@
 void dict_atomic_inc(struct dict_transaction_context *ctx,
 		     const char *key, long long diff)
 {
-	ctx->dict->v.atomic_inc(ctx, key, diff);
+	if (diff != 0)
+		ctx->dict->v.atomic_inc(ctx, key, diff);
 }



More information about the dovecot-cvs mailing list