3,882
社区成员
发帖
与我相关
我的任务
分享
vals = ldap_get_values( ld_, msg_entry, item );
int val_count = ldap_count_values(vals);
for (int k=0; k<val_count; k++)
{
char* value = vals[k];
}
Return value
If the function succeeds, it returns a null-terminated list of pointers to values. If no attribute values were found, it usually returns NULL. But in some cases it may return a list one pointer that is NULL. Always make sure to use ldap_count_values to get the count of values in the returned list, as noted in Remarks. The session error parameter in the LDAP data structure is set to 0 in either case.
If the function fails, it returns NULL and the session error parameter in the LDAP data structure is set to the LDAP error code.