ALT Linux Bugzilla
– Attachment 2457 Details for
Bug 14694
Не открывается последний проект, если название его файла содержит не-ascii символы
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
Patch fixing this bug
gnucash-2.2.3-utf8-alt.patch (text/plain), 1.19 KB, created by
Yury Aliaev
on 2008-02-28 17:49:10 MSK
(
hide
)
Description:
Patch fixing this bug
Filename:
MIME Type:
Creator:
Yury Aliaev
Created:
2008-02-28 17:49:10 MSK
Size:
1.19 KB
patch
obsolete
>--- gnucash-2.2.3/src/gnome-utils/gnc-file.c.orig 2008-01-08 04:06:26 +0300 >+++ gnucash-2.2.3/src/gnome-utils/gnc-file.c 2008-02-28 16:19:56 +0300 >@@ -129,9 +129,12 @@ > gtk_dialog_add_button(GTK_DIALOG(file_box), > okbutton, GTK_RESPONSE_ACCEPT); > >- if (starting_dir) >+ if (starting_dir) { >+ char *local_starting_dir = g_filename_from_utf8(starting_dir, -1, NULL, NULL, NULL); > gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER (file_box), >- starting_dir); >+ local_starting_dir); >+ g_free(local_starting_dir); >+ } > > gtk_window_set_modal(GTK_WINDOW(file_box), TRUE); > /* >@@ -172,7 +175,13 @@ > /* nope, a local file name */ > internal_name = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER (file_box)); > } >- file_name = g_strdup(internal_name); >+ if (!g_utf8_validate(internal_name, -1, NULL)) { >+ file_name = g_filename_to_utf8(internal_name, -1, NULL, NULL, NULL); >+ if(!file_name) >+ g_warning("Some characters in the filename is neither UTF-8 nor your local encoding\n"); >+ } >+ if(!file_name) >+ file_name = g_strdup(internal_name); > } > gtk_widget_destroy(GTK_WIDGET(file_box)); > LEAVE("%s", file_name ? file_name : "(null)");
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 14694
:
2457
|
2531
|
2532