summaryrefslogtreecommitdiff
path: root/uisimulator
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2002-05-05 10:28:23 +0000
committerDaniel Stenberg <daniel@haxx.se>2002-05-05 10:28:23 +0000
commit91f165e3daa0957aa27f3439ca60eede128e441e (patch)
tree9026cf04bc39ffdd336841c698ba42762631257f /uisimulator
parentbd16e2fa9491b581df4454bcc6514ef12e06adf6 (diff)
downloadrockbox-91f165e3daa0957aa27f3439ca60eede128e441e.tar.gz
rockbox-91f165e3daa0957aa27f3439ca60eede128e441e.zip
support open() properly so that the root dir works in the archos subdir
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@425 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'uisimulator')
-rw-r--r--uisimulator/x11/io.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/uisimulator/x11/io.c b/uisimulator/x11/io.c
index 4c1e594047..9551d101bb 100644
--- a/uisimulator/x11/io.c
+++ b/uisimulator/x11/io.c
@@ -13,3 +13,16 @@ DIR *x11_opendir(char *name)
13 } 13 }
14 return opendir(name); 14 return opendir(name);
15} 15}
16
17int x11_open(char *name, int opts)
18{
19 char buffer[256]; /* sufficiently big */
20
21 if(name[0] == '/') {
22 sprintf(buffer, "%s/%s", SIMULATOR_ARCHOS_ROOT, name);
23
24 Logf("We open the real file '%s'", buffer);
25 return open(buffer, opts);
26 }
27 return open(name, opts);
28}