aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mail/ChangeLog5
-rw-r--r--mail/mail-config-gui.c12
2 files changed, 15 insertions, 2 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index b620f89f33..98dfd18129 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,8 @@
+2000-10-16 Chris Toshok <toshok@helixcode.com>
+
+ * mail-config-gui.c (service_page_get_url): only set the url->user
+ field if the user string is non-NULL and not empty.
+
2000-10-16 Not Zed <NotZed@HelixCode.com>
* message-list.c (message_list_setup_etable): Uh, fixed jeff's
diff --git a/mail/mail-config-gui.c b/mail/mail-config-gui.c
index 67ad633771..34560647ac 100644
--- a/mail/mail-config-gui.c
+++ b/mail/mail-config-gui.c
@@ -583,8 +583,16 @@ service_page_get_url (MailDialogServicePage *page)
url = g_new0 (CamelURL, 1);
url->protocol = g_strdup (spitem->protocol);
- if (spitem->user)
- url->user = e_utf8_gtk_editable_get_chars (GTK_EDITABLE (spitem->user), 0, -1);
+ if (spitem->user) {
+ char *user = e_utf8_gtk_editable_get_chars (GTK_EDITABLE (spitem->user), 0, -1);
+ if (user && *user) {
+ url->user = user;
+ }
+ else {
+ url->user = NULL;
+ g_free (user);
+ }
+ }
if (spitem->host) {
char *p;