/* $OpenLDAP$ */
-/*
- * Copyright (c) 1996 Regents of the University of Michigan.
+/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
+ *
+ * Copyright 1998-2005 The OpenLDAP Foundation.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted only as authorized by the OpenLDAP
+ * Public License.
+ *
+ * A copy of this license is available in file LICENSE in the
+ * top-level directory of the distribution or, alternatively, at
+ * <http://www.OpenLDAP.org/license.html>.
+ */
+/* Portions Copyright (c) 1996 Regents of the University of Michigan.
* All rights reserved.
*
* Redistribution and use in source and binary forms are permitted
* software without specific prior written permission. This software
* is provided ``as is'' without express or implied warranty.
*/
+/* ACKNOWLEDGEMENTS:
+ * This work was originally developed by the University of Michigan
+ * (as part of U-MICH LDAP).
+ */
/*
* rq.c - routines used to manage the queue of replication entries.
#include "slurp.h"
#include "globals.h"
-
/*
* Lock the replication queue.
*/
/* set the sequence number */
re->re_seq = 0;
- if ( !wasempty && !strcmp(rq->rq_tail->re_timestamp, re->re_timestamp )) {
+ if ( !wasempty && ( rq->rq_tail->re_timestamp == re->re_timestamp )) {
/*
* Our new re has the same timestamp as the tail's timestamp.
* Increment the seq number in the tail and use it as our seq number.
for ( re = rq->rq_gethead( rq ); re != NULL;
re = rq->rq_getnext( re )) {
if ( type == RQ_COUNT_NZRC ) {
- if ( re->re_getrefcnt( re ) > 1 ) {
+ if ( re->re_getrefcnt( re ) > 0 ) {
count++;
}
}