From b5a0acb45a80237d7640118ea11c68f0400bfc88 Mon Sep 17 00:00:00 2001 From: Jeffrey Stedfast Date: Thu, 25 May 2006 18:09:36 +0000 Subject: Replace 'if (!filename)' with 'if (filename)', fixes a bug in Srini's 2006-05-25 Jeffrey Stedfast * e-msg-composer-select-file.c (select_attach_response): Replace 'if (!filename)' with 'if (filename)', fixes a bug in Srini's patch. svn path=/trunk/; revision=32032 --- composer/ChangeLog | 4 ++++ composer/e-msg-composer-select-file.c | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) (limited to 'composer') diff --git a/composer/ChangeLog b/composer/ChangeLog index bcf9e68f19..1f0db2e8fb 100644 --- a/composer/ChangeLog +++ b/composer/ChangeLog @@ -1,5 +1,9 @@ 2006-05-25 Jeffrey Stedfast + * e-msg-composer-select-file.c (select_attach_response): Replace + 'if (!filename)' with 'if (filename)', fixes a bug in Srini's + patch. + * e-msg-composer-hdrs.c (header_new_recipient): Set the visible field to FALSE. diff --git a/composer/e-msg-composer-select-file.c b/composer/e-msg-composer-select-file.c index 430bcb003a..c9e98c0a8e 100644 --- a/composer/e-msg-composer-select-file.c +++ b/composer/e-msg-composer-select-file.c @@ -61,8 +61,8 @@ get_selector(struct _EMsgComposer *composer, const char *title, guint32 flags) { GtkWidget *selection; GtkWidget *showinline = NULL; - char *path; GList *icon_list; + char *path; path = g_object_get_data ((GObject *) composer, "attach_path"); @@ -194,12 +194,12 @@ select_attach_response(GtkWidget *selector, guint response, struct _EMsgComposer EMsgComposerSelectAttachFunc func = g_object_get_data((GObject *)selector, "callback"); GtkToggleButton *showinline = g_object_get_data((GObject *)selector, "show-inline"); char *path = NULL; - + #ifdef USE_GTKFILECHOOSER char *filename = NULL; names = gtk_file_chooser_get_uris (GTK_FILE_CHOOSER (selector)); filename = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (selector)); - if (!filename) { + if (filename) { path = g_path_get_dirname (filename); g_free (filename); } -- cgit