[rhythmbox] file-helpers: get symlink target as byte string, not ASCII (bug #594008)
- From: Jonathan Matthew <jmatthew src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [rhythmbox] file-helpers: get symlink target as byte string, not ASCII (bug #594008)
- Date: Sat, 5 Sep 2009 02:29:33 +0000 (UTC)
commit 88b813f430342ee47bf3e877b29ece31ec4b9dca
Author: Jonathan Matthew <jonathan d14n org>
Date: Sat Sep 5 12:28:26 2009 +1000
file-helpers: get symlink target as byte string, not ASCII (bug #594008)
lib/rb-file-helpers.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/lib/rb-file-helpers.c b/lib/rb-file-helpers.c
index 0d9e701..d9c6bac 100644
--- a/lib/rb-file-helpers.c
+++ b/lib/rb-file-helpers.c
@@ -316,7 +316,7 @@ rb_uri_resolve_symlink (const char *uri, GError **error)
while (link_count < MAX_LINK_LEVEL) {
GFile *parent;
GFile *new_file;
- char *target;
+ const char *target;
/* look for a symlink target */
file_info = g_file_query_info (file,
@@ -347,10 +347,8 @@ rb_uri_resolve_symlink (const char *uri, GError **error)
break;
}
- target = g_file_info_get_attribute_as_string (file_info, attr);
-
+ target = g_file_info_get_attribute_byte_string (file_info, attr);
new_file = g_file_resolve_relative_path (parent, target);
- g_free (target);
g_object_unref (parent);
g_object_unref (file_info);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]