changeset 3167:49c25e9ecf6d trunk

Unbreak vfs_is_writeable().
author William Pitcock <nenolod@atheme-project.org>
date Wed, 25 Jul 2007 16:28:54 -0500
parents 56121fc7a4cb
children ee8a1ed30826
files src/audacious/vfs.c
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/audacious/vfs.c	Wed Jul 25 15:46:06 2007 -0500
+++ b/src/audacious/vfs.c	Wed Jul 25 16:28:54 2007 -0500
@@ -383,10 +383,13 @@
 vfs_is_writeable(const gchar * path)
 {
     struct stat info;
+    gchar *realfn = g_filename_from_uri(path, NULL, NULL);
 
-    if (stat(path, &info) == -1)
+    if (stat(realfn, &info) == -1)
         return FALSE;
 
+    g_free(realfn);
+
     return (info.st_mode & S_IWUSR);
 }