ldap_sort_values

Sorts an array of values retrieved from an ldap_get_values function.

LDAP Version:v2 or higher
Library:*ldapsdk.*
NDS Version:7.xx or higher
Platform:NLM, Windows (NT, 95, 98, 2000, XP, Vista 32-bit and 64-bit ), Linux (32-bit and 64-bit), Solaris, AIX, and HP-UX

Syntax

  #include <ldap.h>
  
  int ldap_sort_values (
     LDAP    *ld,
     char   **vals,
     int    (*cmp) (const void *, const void *));
  
  

Parameters

ld

(IN) Points to the handle of the LDAP session.

vals

(IN) Points to the array of values to sort.

cmp

(IN) Points to the function to use for sorting.This function returns an int and has two void pointers for parameters. The ldap_sort_strcasecmp function can be used for this parameter to compare ASCII strings.

Return Values

0x00

LDAP_SUCCESS

Non-zero

Failure. See LDAP Return Codes.

See Also

ldap_get_values, ldap_sort_strcasecmp