apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Graham Leggett <minf...@sharp.fm>
Subject Re: apr-util + LDAP: How to handle status codes
Date Wed, 01 Aug 2001 10:45:35 GMT
Justin Erenkrantz wrote:

> > Is this the right way to do things? Or should there be a mapping to
> > APR_LDAP_* status codes from LDAP_* status codes?
> I'd suggest that we should map the APR_LDAP_* status codes from LDAP_*.
> We can do this by allocating an offset.  So, just do:
> apr_status_t status = ldap_fn_result_code + APR_LDAP_ERROR_START;
> or something like that.  We have that precedent somewhere.  How many
> numbers would we need?  I don't remember how many the LDAP library
> defines.  -- justin

There are about 100 or so (as a guess).

A potential problem though - apr_error.h is defined in APR. The LDAP_*
error codes are only defined if the LDAP libraries are included in

Would the APR_LDAP_* codes go in APR or APR-util? (they could
practically only go in the second one).

Would the right approach then be to define APR_LDAP_ERROR_START in APR,
and then the actual error codes themselves in APR-util? (in apr_ldap.h,
or something else?).

minfrin@sharp.fm		"There's a moon
					over Bourbon Street
View raw message