[dovecot-cvs] dovecot/src/lib array.h,1.7,1.8

cras at dovecot.org cras at dovecot.org
Sun Apr 3 00:09:05 EEST 2005


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

Modified Files:
	array.h 
Log Message:
Keywords are now stored in X-Keywords headers in mbox. Did several related
API changes to get better performance.



Index: array.h
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib/array.h,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- array.h	2 Apr 2005 19:31:26 -0000	1.7
+++ array.h	2 Apr 2005 21:09:02 -0000	1.8
@@ -281,4 +281,16 @@
 	return array->buffer->used / array->element_size;
 }
 
+static inline int
+array_cmp(const array_t *array1, const array_t *array2)
+{
+	if (!array_is_created(array1) || array1->buffer->used == 0)
+		return !array_is_created(array2) || array2->buffer->used == 0;
+
+	if (!array_is_created(array2))
+		return FALSE;
+
+	return buffer_cmp(array1->buffer, array2->buffer);
+}
+
 #endif



More information about the dovecot-cvs mailing list