hmm... I'm not quite sure how to attach a file to a ticket through the
web interface, so I'm just going to paste the patches in here:
--- ldap.h.1.349.orig 2010-04-02 15:32:34.113126200 -0500
+++ ldap.h 2010-04-02 15:33:55.252793400 -0500
@@ -1841,7 +1841,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPControl **serverctrls,
LDAPControl **clientctrls,
@@ -1855,7 +1855,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPControl **serverctrls,
LDAPControl **clientctrls,
@@ -1870,7 +1870,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly ));
=20
LDAP_F( int )
@@ -1879,7 +1879,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPMessage **res ));
=20
@@ -1889,7 +1889,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
struct timeval *timeout,
LDAPMessage **res ));
--- search.c.1.88.orig 2010-04-02 15:26:34.268550800 -0500
+++ search.c 2010-04-02 15:32:36.939198200 -0500
@@ -47,7 +47,7 @@
* attrsonly 1 =3D> attributes only 0 =3D> attributes and values
*
* Example:
- * char *attrs[] =3D { "mail", "title", 0 };
+ * const char *attrs[] =3D { "mail", "title", 0 };
* ldap_search_ext( ld, "dc=3Dexample,dc=3Dcom", LDAP_SCOPE_SUBTREE,
"cn~=3Dbob",
* attrs, attrsonly, sctrls, ctrls, timeout, sizelimit,
* &msgid );
@@ -58,7 +58,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPControl **sctrls,
LDAPControl **cctrls,
@@ -76,7 +76,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPControl **sctrls,
LDAPControl **cctrls,
@@ -139,7 +139,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPControl **sctrls,
LDAPControl **cctrls,
@@ -157,7 +157,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPControl **sctrls,
LDAPControl **cctrls,
@@ -210,14 +210,14 @@
* attrsonly 1 =3D> attributes only 0 =3D> attributes and values
*
* Example:
- * char *attrs[] =3D { "mail", "title", 0 };
+ * const char *attrs[] =3D { "mail", "title", 0 };
* msgid =3D ldap_search( ld, "dc=3Dexample,dc=3Dcom",
LDAP_SCOPE_SUBTREE, "cn~=3Dbob",
* attrs, attrsonly );
*/
int
ldap_search(
LDAP *ld, LDAP_CONST char *base, int scope, LDAP_CONST char
*filter,
- char **attrs, int attrsonly )
+ LDAP_CONST char **attrs, int attrsonly )
{
BerElement *ber;
ber_int_t id;
@@ -246,7 +246,7 @@
LDAP_CONST char *base,
ber_int_t scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
ber_int_t attrsonly,
LDAPControl **sctrls,
LDAPControl **cctrls,
@@ -390,7 +390,7 @@
int
ldap_search_st(
LDAP *ld, LDAP_CONST char *base, int scope,
- LDAP_CONST char *filter, char **attrs,
+ LDAP_CONST char *filter, LDAP_CONST char **attrs,
int attrsonly, struct timeval *timeout, LDAPMessage **res )
{
int msgid;
@@ -419,7 +419,7 @@
LDAP_CONST char *base,
int scope,
LDAP_CONST char *filter,
- char **attrs,
+ LDAP_CONST char **attrs,
int attrsonly,
LDAPMessage **res )
{