]> git.sur5r.net Git - openldap/blobdiff - libraries/libldap/compare.c
Add O_EXCL
[openldap] / libraries / libldap / compare.c
index 83d7ec125e934325daa614f8e27b0f6f3b25576c..bb13bcc11f511a673d8a43b51df26c8937b04798 100644 (file)
@@ -29,6 +29,7 @@
 #include <ac/time.h>
 
 #include "ldap-int.h"
+#include "ldap_log.h"
 
 /*
  * ldap_compare_ext - perform an ldap extended compare operation.  The dn
@@ -55,7 +56,7 @@ ldap_compare_ext(
        BerElement      *ber;
 
 #ifdef NEW_LOGGING
-       LDAP_LOG (( "compare", LDAP_LEVEL_ENTRY, "ldap_compare\n" ));
+       LDAP_LOG ( OPERATION, ENTRY, "ldap_compare\n", 0, 0, 0 );
 #else
        Debug( LDAP_DEBUG_TRACE, "ldap_compare\n", 0, 0, 0 );
 #endif
@@ -131,6 +132,8 @@ ldap_compare(
        int msgid;
        struct berval bvalue;
 
+       assert( value != NULL );
+
        bvalue.bv_val = (char *) value;
        bvalue.bv_len = (value == NULL) ? 0 : strlen( value );
 
@@ -171,6 +174,8 @@ ldap_compare_s(
 {
        struct berval bvalue;
 
+       assert( value != NULL );
+
        bvalue.bv_val = (char *) value;
        bvalue.bv_len = (value == NULL) ? 0 : strlen( value );