aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorArmin Weatherwax2010-01-01 13:34:42 +0100
committerJacek Antonelli2010-04-29 01:15:00 -0500
commitcb52288af00406eb460d38d48960a5bf228e2126 (patch)
tree04c3ff442aa288c95e5c573df526c15f1b35a586
parentFix just another hardcoded path to Linux-i686. (diff)
downloadmeta-impy-cb52288af00406eb460d38d48960a5bf228e2126.zip
meta-impy-cb52288af00406eb460d38d48960a5bf228e2126.tar.gz
meta-impy-cb52288af00406eb460d38d48960a5bf228e2126.tar.bz2
meta-impy-cb52288af00406eb460d38d48960a5bf228e2126.tar.xz
Fix filepicker not working in 64bit build.
(Backported from 3e56d26c) @nochangelog
-rw-r--r--linden/indra/newview/llfilepicker.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/linden/indra/newview/llfilepicker.cpp b/linden/indra/newview/llfilepicker.cpp
index ece30dd..dbb218a 100644
--- a/linden/indra/newview/llfilepicker.cpp
+++ b/linden/indra/newview/llfilepicker.cpp
@@ -917,8 +917,9 @@ void LLFilePicker::add_to_selectedfiles(gpointer data, gpointer user_data)
917 917
918 LLFilePicker* picker = (LLFilePicker*) user_data; 918 LLFilePicker* picker = (LLFilePicker*) user_data;
919 GError *error = NULL; 919 GError *error = NULL;
920 gchar* filename_utf8 = g_filename_to_utf8((gchar*)data, 920// gchar* filename_utf8 = g_filename_to_utf8((gchar*)data,
921 -1, NULL, NULL, &error); 921// -1, NULL, NULL, &error);
922 gchar* filename_utf8 = g_filename_display_name ((gchar*) data);
922 if (error) 923 if (error)
923 { 924 {
924 // This condition should really be notified to the user, e.g., 925 // This condition should really be notified to the user, e.g.,
@@ -930,12 +931,10 @@ void LLFilePicker::add_to_selectedfiles(gpointer data, gpointer user_data)
930 // writing is 2.22. *sigh*) LL supplied *makeASCII family are 931 // writing is 2.22. *sigh*) LL supplied *makeASCII family are
931 // also unsuitable since they allow control characters... 932 // also unsuitable since they allow control characters...
932 933
933 std::string display_name; 934 // muhahaha ... Imprudence can !
934 for (const gchar *str = (const gchar *)data; *str; str++) 935
935 { 936
936 display_name += (char)((*str >= 0x20 && *str <= 0x7E) ? *str : '?'); 937 llwarns << "g_filename_display_name failed on" << filename_utf8 << ": "<< error->message << llendl;
937 }
938 llwarns << "g_filename_to_utf8 failed on \"" << display_name << "\": " << error->message << llendl;
939 } 938 }
940 939
941 if (filename_utf8) 940 if (filename_utf8)