Open Bug 351554 Opened 18 years ago Updated 18 years ago

use ber_ typedefs for ldap_msgtype() and ldap_msgid() return values

Categories

(Directory :: LDAP C SDK, defect)

defect
Not set
normal

Tracking

(Not tracked)

People

(Reporter: mcs, Assigned: mcs)

Details

Ideally ldap_msgtype() would return a ber_tag_t.
And ldap_msgid()would return a ber_int_t.

This bug report is a spinoff of bug 347933.  For now, we are leaving the return types for ldap_msgtype() and ldap_msgid() as-is (they both return an int, which is consistent with OpenLDAP and with the expired C API Internet Draft).

Note that if we change ldap_msgid() to return a ber_int_t we should also change the lm_msgid field inside the ldapmsg struct to a ber_int_t... and also change many integers in calls such as ldap_result().  That is a fairly large change.
Anton wisely said (in a comment in bug 347933):
> Mark, i agree they need to be changed, ideally, however with OpenLDAP
> keeping them as int right now and as noted by Rich we have it working
> anyway on every platform we care about i would rather go for
> compatibility than 100% clean implementation in this case. i think
> OpenLDAP kept them as int because of the draft. another way to approach
> this is to ask OpenLDAP folks if they w/gonna change their implementation
> and if so we can do the same, staying compatible.
You need to log in before you can comment on or make changes to this bug.