From 10451271268c699cdd23f1cfaf61be1cf56f0883 Mon Sep 17 00:00:00 2001 From: Jeffrey Stedfast Date: Tue, 29 Jan 2002 22:51:40 +0000 Subject: Don't pass NULL text to gtk_entry_set_text. Maybe this will fix bug 2002-01-29 Jeffrey Stedfast * mail-accounts.c (construct): Don't pass NULL text to gtk_entry_set_text. Maybe this will fix bug #18971. svn path=/trunk/; revision=15512 --- mail/ChangeLog | 5 +++++ mail/mail-accounts.c | 10 +++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/mail/ChangeLog b/mail/ChangeLog index 09552a220a..fcb5d5f223 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,3 +1,8 @@ +2002-01-29 Jeffrey Stedfast + + * mail-accounts.c (construct): Don't pass NULL text to + gtk_entry_set_text. Maybe this will fix bug #18971. + 2002-01-29 Jeffrey Stedfast * mail-callbacks.c (redirect): New function that implements the diff --git a/mail/mail-accounts.c b/mail/mail-accounts.c index f00be07739..db8a09a481 100644 --- a/mail/mail-accounts.c +++ b/mail/mail-accounts.c @@ -808,6 +808,7 @@ construct (MailAccountsDialog *dialog) { GladeXML *gui; GtkWidget *notebook, *menu; + const char *text; int num; gui = glade_xml_new (EVOLUTION_GLADEDIR "/mail-config.glade", NULL); @@ -947,8 +948,9 @@ construct (MailAccountsDialog *dialog) /* Other page */ dialog->pgp_path = GNOME_FILE_ENTRY (glade_xml_get_widget (gui, "filePgpPath")); + text = mail_config_get_pgp_path (); gtk_entry_set_text (GTK_ENTRY (gnome_file_entry_gtk_entry (dialog->pgp_path)), - mail_config_get_pgp_path ()); + text ? text : ""); gnome_file_entry_set_default_path (dialog->pgp_path, mail_config_get_pgp_path ()); gtk_signal_connect (GTK_OBJECT (gnome_file_entry_gtk_entry (dialog->pgp_path)), "changed", GTK_SIGNAL_FUNC (pgp_path_changed), dialog); @@ -970,8 +972,9 @@ construct (MailAccountsDialog *dialog) GTK_SIGNAL_FUNC (filter_log_toggled), dialog); dialog->filter_log_path = GNOME_FILE_ENTRY (glade_xml_get_widget (gui, "fileFilterLog")); + text = mail_config_get_filter_log_path (); gtk_entry_set_text (GTK_ENTRY (gnome_file_entry_gtk_entry (dialog->filter_log_path)), - mail_config_get_filter_log_path ()); + text ? text : ""); gnome_file_entry_set_default_path (dialog->filter_log_path, mail_config_get_filter_log_path ()); gtk_signal_connect (GTK_OBJECT (gnome_file_entry_gtk_entry (dialog->filter_log_path)), "changed", GTK_SIGNAL_FUNC (filter_log_path_changed), dialog); @@ -998,8 +1001,9 @@ construct (MailAccountsDialog *dialog) GTK_SIGNAL_FUNC (notify_radio_toggled), dialog); dialog->notify_sound_file = GNOME_FILE_ENTRY (glade_xml_get_widget (gui, "fileNotifyPlaySound")); + text = mail_config_get_new_mail_notify_sound_file (); gtk_entry_set_text (GTK_ENTRY (gnome_file_entry_gtk_entry (dialog->notify_sound_file)), - mail_config_get_new_mail_notify_sound_file ()); + text ? text : ""); gtk_signal_connect (GTK_OBJECT (gnome_file_entry_gtk_entry (dialog->notify_sound_file)), "changed", GTK_SIGNAL_FUNC (notify_sound_file_changed), dialog); -- cgit