Changeset 107395 in webkit
- Timestamp:
- Feb 10, 2012 3:51:05 AM (12 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r107394 r107395 1 2012-02-10 Carlos Garcia Campos <cgarcia@igalia.com> 2 3 [GTK] KURL::fileSystemPath() doesn't work if uri contains # 4 https://bugs.webkit.org/show_bug.cgi?id=78339 5 6 Reviewed by Philippe Normand. 7 8 * platform/gtk/KURLGtk.cpp: 9 (WebCore::KURL::fileSystemPath): Use GFile API instead of 10 g_filename_from_uri() to convert the uri to a local 11 path. g_file_get_path() removes the anchor from the uri and 12 returns a valid path instead of NULL. 13 1 14 2012-02-10 Pablo Flouret <pablof@motorola.com> 2 15 -
trunk/Source/WebCore/platform/gtk/KURLGtk.cpp
r95901 r107395 21 21 22 22 #include "FileSystem.h" 23 #include <gio/gio.h> 24 #include <wtf/gobject/GOwnPtr.h> 25 #include <wtf/gobject/GRefPtr.h> 23 26 #include <wtf/text/CString.h> 24 27 … … 29 32 String KURL::fileSystemPath() const 30 33 { 31 gchar* filename = g_filename_from_uri(m_string.utf8().data(), 0, 0); 32 if (!filename) 33 return String(); 34 35 String path = filenameToString(filename); 36 g_free(filename); 37 return path; 34 GRefPtr<GFile> file = adoptGRef(g_file_new_for_uri(m_string.utf8().data())); 35 GOwnPtr<char> filename(g_file_get_path(file.get())); 36 return filenameToString(filename.get()); 38 37 } 39 38
Note: See TracChangeset
for help on using the changeset viewer.