[Date Prev][Date Next] [Chronological] [Thread] [Top]

LDAP C phooey

I should receive lashings for such a fundamental question but its
keeping me up at night because I can't figure it out.

I have function that wraps the ldap_init call (this is my example so
don't ask why I would do such a thing) and one of the arguments is LDAP*
ld.  This signature is...

int my_ldap_init(LDAP* ld);

in my main function I do something like this ...

int main()
	LDAP main_ld;


Now my brain tells me that this should initialize main_ld with a valid
LDAP structure, but it doesn't.  Since I've no declare my brain defunct,
I could really use yours.  

I did do a sanity check and found that the typical swap(int*,int*)
function works fine.


Noah Campbell
Web Developer