ldap.ENCODING_ERROR when trying to use SimplePageResultsControl
Zhang Huangbin
zhbmaillistonly at gmail.com
Sun Mar 15 11:51:12 CET 2009
I had the same error here while run Demo/page_control.py:
----
Traceback (most recent call last):
File "1.py", line 23, in ?
serverctrls=[lc]
File
"/usr/lib64/python2.4/site-packages/python_ldap-2.3.6-py2.4-linux-x86_64.egg/ldap/ldapobject.py",
line 501, in search_ext_s
msgid =
self.search_ext(base,scope,filterstr,attrlist,attrsonly,serverctrls,clientctrls,timeout,sizelimit)
File
"/usr/lib64/python2.4/site-packages/python_ldap-2.3.6-py2.4-linux-x86_64.egg/ldap/ldapobject.py",
line 495, in search_ext
EncodeControlTuples(serverctrls),
File
"/usr/lib64/python2.4/site-packages/python_ldap-2.3.6-py2.4-linux-x86_64.egg/ldap/controls.py",
line 110, in EncodeControlTuples
result = [
File
"/usr/lib64/python2.4/site-packages/python_ldap-2.3.6-py2.4-linux-x86_64.egg/ldap/controls.py",
line 45, in getEncodedTuple
return
(self.controlType,self.criticality,self.encodeControlValue(self.controlValue))
File
"/usr/lib64/python2.4/site-packages/python_ldap-2.3.6-py2.4-linux-x86_64.egg/ldap/controls.py",
line 78, in encodeControlValue
return _ldap.encode_page_control(size,cookie)
ldap.ENCODING_ERROR
----
My env:
OS: RHEL 5.3, x86_64
Python: 2.4.3-24.el5 (shipped within RHEL 5.3)
python-ldap: 2.3.6 (installed from source tarball)
OpenLDAP: 2.3.43-3.el5 (shipped within RHEL 5.3)
How can i solve it?
--
Best regards.
Zhang Huangbin
- Open Source Mail Server Solution for RHEL/CentOS 5.x:
http://code.google.com/p/iredmail/
More information about the python-ldap
mailing list