summaryrefslogtreecommitdiffstats
path: root/ldap/servers/plugins/syntaxes
diff options
context:
space:
mode:
Diffstat (limited to 'ldap/servers/plugins/syntaxes')
-rw-r--r--ldap/servers/plugins/syntaxes/bin.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/ldap/servers/plugins/syntaxes/bin.c b/ldap/servers/plugins/syntaxes/bin.c
index b7be0d1a..2d0b6f8a 100644
--- a/ldap/servers/plugins/syntaxes/bin.c
+++ b/ldap/servers/plugins/syntaxes/bin.c
@@ -165,8 +165,10 @@ bin_filter_ava( Slapi_PBlock *pb, struct berval *bvfilter,
int i;
for ( i = 0; bvals[i] != NULL; i++ ) {
- if ( slapi_value_get_length(bvals[i]) == bvfilter->bv_len &&
- 0 == memcmp( slapi_value_get_string(bvals[i]), bvfilter->bv_val, bvfilter->bv_len ))
+ const struct berval *bv = slapi_value_get_berval(bvals[i]);
+
+ if ( ( bv->bv_len == bvfilter->bv_len ) &&
+ ( 0 == memcmp( bv->bv_val, bvfilter->bv_val, bvfilter->bv_len ) ) )
{
if(retVal!=NULL)
{