2011-04-08 [colin] 3.7.8cvs73
authorColin Leroy <colin@colino.net>
Fri, 8 Apr 2011 14:50:22 +0000 (14:50 +0000)
committerColin Leroy <colin@colino.net>
Fri, 8 Apr 2011 14:50:22 +0000 (14:50 +0000)
* src/gtk/filesel.c
Fix bug #2393, "Crashes and rendering problems in the "Save as" menu
caused by attachments with extended chars in the file name". Patch
derived from a patch bt Fabien Keil

ChangeLog
PATCHSETS
configure.ac
src/gtk/filesel.c

index a1ece7e..3f3e449 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-04-08 [colin]     3.7.8cvs73
+
+       * src/gtk/filesel.c
+               Fix bug #2393, "Crashes and rendering problems in the "Save as" menu 
+               caused by attachments with extended chars in the file name". Patch
+               derived from a patch bt Fabien Keil
+
 2011-04-05 [wwp]       3.7.8cvs72
 
        * src/compose.c
index cde338c..d95bb1d 100644 (file)
--- a/PATCHSETS
+++ b/PATCHSETS
 ( cvs diff -u -r 1.382.2.568 -r 1.382.2.569 src/compose.c;  ) > 3.7.8cvs70.patchset
 ( cvs diff -u -r 1.20.2.76 -r 1.20.2.77 src/common/utils.h;  ) > 3.7.8cvs71.patchset
 ( cvs diff -u -r 1.382.2.569 -r 1.382.2.570 src/compose.c;  ) > 3.7.8cvs72.patchset
+( cvs diff -u -r 1.2.2.42 -r 1.2.2.43 src/gtk/filesel.c;  ) > 3.7.8cvs73.patchset
index a85a3b6..12457b0 100644 (file)
@@ -12,7 +12,7 @@ MINOR_VERSION=7
 MICRO_VERSION=8
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=72
+EXTRA_VERSION=73
 EXTRA_RELEASE=
 EXTRA_GTK2_VERSION=
 
index 50127a0..a511aab 100644 (file)
@@ -168,21 +168,13 @@ static GList *filesel_create(const gchar *title, const gchar *path,
                        g_free(realpath); 
                        realpath = g_strdup(get_home_dir());
                }
-               tmp = NULL;
                if (g_utf8_validate(realpath, -1, NULL))
-                       tmp = g_filename_from_utf8(realpath, -1, NULL, NULL, NULL);
-               if (tmp == NULL)
-                       tmp = g_strdup(realpath);
-               gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(chooser), tmp);
-               g_free(tmp);
+                       gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(chooser),
+                                                           realpath);
                if (action == GTK_FILE_CHOOSER_ACTION_SAVE) {
-                       tmp = NULL;
                        if (g_utf8_validate(filename, -1, NULL))
-                               tmp = g_filename_from_utf8(filename, -1, NULL, NULL, NULL);
-                       if (tmp == NULL)
-                               tmp = g_strdup(filename);
-                       gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(chooser), tmp);
-                       g_free(tmp);
+                               gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(chooser),
+                                                                 filename);
                }
                g_free(realpath);
        } else {