Implementation of LDAPControls

Deepak Giridharagopal deepak at
Fri Feb 25 22:06:31 CET 2005

On Fri, 2005-02-25 at 18:29 +0100, Michael Ströder wrote:
> I've committed your patches to CVS since they seem to be the most 
> complete solution. 

Great! :) 

Regarding your suggestions, I've attached a new patch (I diff'ed against
the cvs HEAD). 

> But I'd really prefer to have code without 
> goto-statements. Could you please work out a solution for this? 


(FWIW, I'd prefer to have code without goto-statements, too, but I'm of
the opinion that error handling in C is one of the few situations in
which goto's actually *help* readability. But since you're the boss,
I'll heed your conventions. :) )

> And 
> maybe it would be nice to extract the helper functions for LDAPControls 
> to a separate C source text called ldapcontrols.c?


> One thing I wonder about is whether it's possible to send a control 
> where the control value is absent (e.g. by passing None as control 
> value)? See RFC3296 chapter 3 for an example (ManageDsaIT Control).


(Before, an error would have been thrown. Now, 'None' is permitted.)

> Thanks again for working on it!

No problem. :)


Deepak Giridharagopal
Applied Research Laboratories
University of Texas at Austin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ldapcontrols_take2.patch
Type: text/x-patch
Size: 10846 bytes
URL: <>

More information about the python-ldap mailing list