summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSushma Rai <rsushma@src.gnome.org>2005-08-13 06:27:51 +0000
committerSushma Rai <rsushma@src.gnome.org>2005-08-13 06:27:51 +0000
commitb398a89d5f7add2d3ca88ca2d4b221e3a8d4e6d8 (patch)
tree5d7a7f07250ddd71ed4f14a7501866ebaee55965
parentc51228f3142b3974813483008a55cad57cceb790 (diff)
downloadevolution-data-server-b398a89d5f7add2d3ca88ca2d4b221e3a8d4e6d8.tar.gz
Not retrieving and displaying entire LDAP address book in name selector dialog.
-rw-r--r--addressbook/ChangeLog6
-rw-r--r--addressbook/backends/ldap/e-book-backend-ldap.c6
2 files changed, 12 insertions, 0 deletions
diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog
index 345312d09..81c6260bb 100644
--- a/addressbook/ChangeLog
+++ b/addressbook/ChangeLog
@@ -1,5 +1,11 @@
2005-08-13 Sushma Rai <rsushma@novell.com>
+ * backends/ldap/e-book-backend-ldap.c (func_beginswith): Ignoring the
+ null query for LDAP addressbook, so that we don't download the book and
+ try to show all the entries in name selector dialog.
+
+2005-08-13 Sushma Rai <rsushma@novell.com>
+
* backends/ldap/e-book-backend-ldap.c
(e_book_backend_ldap_authenticate_user): Return error if we fail to
get the DN for the user.
diff --git a/addressbook/backends/ldap/e-book-backend-ldap.c b/addressbook/backends/ldap/e-book-backend-ldap.c
index 639f795f0..aa198d58f 100644
--- a/addressbook/backends/ldap/e-book-backend-ldap.c
+++ b/addressbook/backends/ldap/e-book-backend-ldap.c
@@ -2932,6 +2932,12 @@ func_beginswith(struct _ESExp *f, int argc, struct _ESExpResult **argv, void *da
char *str = rfc2254_escape(argv[1]->value.string);
char *ldap_attr = query_prop_to_ldap(propname);
+ if (strlen (str) == 0) {
+ r = e_sexp_result_new (f, ESEXP_RES_BOOL);
+ r->value.bool = FALSE;
+ return r;
+ }
+
/* insert hack for fileAs queries, since we need to do
the right thing if the server supports them or not,
and for entries that have no fileAs attribute. */