summaryrefslogtreecommitdiffstats
path: root/apps/tree.c
diff options
context:
space:
mode:
authorThomas Martitz <kugel@rockbox.org>2010-08-02 19:13:22 +0000
committerThomas Martitz <kugel@rockbox.org>2010-08-02 19:13:22 +0000
commit850efead04f10488b478a0f255a2464a01156a7f (patch)
tree44539bf63d893479c83f8cee8c4a9ca09b773dc5 /apps/tree.c
parent75556fd57ff70be9a9cbc183cbacb71db520291d (diff)
downloadrockbox-850efead04f10488b478a0f255a2464a01156a7f.tar.gz
rockbox-850efead04f10488b478a0f255a2464a01156a7f.zip
A few post-fixes to the get_user_file_path() commit.
Remove unneeded restriction from set_file that prevented filename settings to work if they were outside of ROCKBOX_DIR. Add the get_user_file_path() call to a few further places where it was forgotten. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27667 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/tree.c')
-rw-r--r--apps/tree.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/tree.c b/apps/tree.c
index ed8e4d20bd..c2ec4ca3ec 100644
--- a/apps/tree.c
+++ b/apps/tree.c
@@ -988,9 +988,10 @@ int rockbox_browse(const char *root, int dirfilter)
/* If we've found a file to center on, do it */
if (setting)
{
- char current[MAX_PATH];
+ char current[MAX_PATH], _dir[MAX_PATH];
/* if setting != NULL, ext and dir are not used uninitialized */
- snprintf(current, sizeof(current), "%s/%s.%s", dir, setting, ext);
+ snprintf(current, sizeof(current), "%s/%s.%s",
+ get_user_file_path(dir, 0, _dir, sizeof(_dir)), setting, ext);
set_current_file(current);
/* set_current_file changes dirlevel, change it back */
tc.dirlevel = 0;