Mercurial > audlegacy
comparison src/audacious/vfs.c @ 2381:d49913587458 trunk
[svn] - changes to the nature of URI handling in the VFS subsystem, will be
chased momentarily in plugins.
author | nenolod |
---|---|
date | Sun, 21 Jan 2007 20:45:17 -0800 |
parents | e1513290ee3c |
children | 0fd7f4f969ad |
comparison
equal
deleted
inserted
replaced
2380:825c3715b90f | 2381:d49913587458 |
---|---|
69 gchar *decpath; | 69 gchar *decpath; |
70 | 70 |
71 if (!path || !mode) | 71 if (!path || !mode) |
72 return NULL; | 72 return NULL; |
73 | 73 |
74 decpath = xmms_urldecode_plain(path); | 74 decpath = g_strdup(path); |
75 | 75 |
76 for (node = vfs_transports; node != NULL; node = g_list_next(node)) | 76 for (node = vfs_transports; node != NULL; node = g_list_next(node)) |
77 { | 77 { |
78 vtable = (VFSConstructor *) node->data; | 78 vtable = (VFSConstructor *) node->data; |
79 | 79 |
83 | 83 |
84 /* no transport vtable has been registered, bail. */ | 84 /* no transport vtable has been registered, bail. */ |
85 if (vtable == NULL) | 85 if (vtable == NULL) |
86 return NULL; | 86 return NULL; |
87 | 87 |
88 if (strlen(vtable->uri_id) > 1) | 88 file = vtable->vfs_fopen_impl(decpath, mode); |
89 file = vtable->vfs_fopen_impl(decpath + strlen(vtable->uri_id), mode); | |
90 else | |
91 file = vtable->vfs_fopen_impl(decpath, mode); | |
92 | 89 |
93 if (file == NULL) | 90 if (file == NULL) |
94 return NULL; | 91 return NULL; |
95 | 92 |
96 file->uri = g_strdup(path); | 93 file->uri = g_strdup(path); |