(ldap-get-values): if ldap_get_values() returns NULL, that's not

necessarily an error
(ldap-entry-dn): renamed ldap-message-dn to ldap-entry-dn
This commit is contained in:
eknauel 2004-02-12 15:49:18 +00:00
parent a2709c19b9
commit fcf3a94b1c
1 changed files with 9 additions and 4 deletions

View File

@ -268,8 +268,13 @@
"scsh_ldap_get_values")
(define (ldap-get-values session entry attribute-name)
(or (ldap-get-values-internal session (ldap-entry-message entry) attribute-name)
(raise-ldap-condition (ldap-get-error-return-object session) session)))
(let ((val (ldap-get-values-internal
session (ldap-entry-message entry) attribute-name)))
(or val
(let ((ret-obj (ldap-get-error-return-object session)))
(if (ldap-success? ret-obj)
val
(raise-ldap-condition ret-obj session))))))
;;;
@ -292,8 +297,8 @@
(session message)
"scsh_ldap_get_dn")
(define (ldap-message-dn session entry)
(or (ldap-get-dn-internal session entry)
(define (ldap-entry-dn session entry)
(or (ldap-get-dn-internal session (ldap-entry-message entry))
(raise-ldap-condition (ldap-get-error-return-object session) session)))
;;;