summaryrefslogtreecommitdiff
path: root/firmware/common/dir_uncached.c
diff options
context:
space:
mode:
authorMaurus Cuelenaere <mcuelenaere@gmail.com>2009-11-26 17:39:30 +0000
committerMaurus Cuelenaere <mcuelenaere@gmail.com>2009-11-26 17:39:30 +0000
commiteab70ca28cbbed89a6f6064377e7189ecc595ac2 (patch)
tree0283a5c31ef7fc2f29c5f4673a185bfb8f4364b6 /firmware/common/dir_uncached.c
parent5afb4a97c205914494e3957f2c57bb322db29d1c (diff)
downloadrockbox-eab70ca28cbbed89a6f6064377e7189ecc595ac2.zip
rockbox-eab70ca28cbbed89a6f6064377e7189ecc595ac2.tar.gz
rockbox-eab70ca28cbbed89a6f6064377e7189ecc595ac2.tar.bz2
rockbox-eab70ca28cbbed89a6f6064377e7189ecc595ac2.tar.xz
- Split off strip_volume() to a separate file
- fix some yellows git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23762 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/common/dir_uncached.c')
-rw-r--r--firmware/common/dir_uncached.c30
1 files changed, 0 insertions, 30 deletions
diff --git a/firmware/common/dir_uncached.c b/firmware/common/dir_uncached.c
index dd157f0..ef9ce6f 100644
--- a/firmware/common/dir_uncached.c
+++ b/firmware/common/dir_uncached.c
@@ -35,36 +35,6 @@
static DIR_UNCACHED opendirs[MAX_OPEN_DIRS];
-#ifdef HAVE_MULTIVOLUME
-
-/* returns on which volume this is, and copies the reduced name
- (sortof a preprocessor for volume-decorated pathnames) */
-int strip_volume(const char* name, char* namecopy)
-{
- int volume = 0;
- const char *temp = name;
-
- while (*temp == '/') /* skip all leading slashes */
- ++temp;
-
- if (*temp && !strncmp(temp, VOL_NAMES, VOL_ENUM_POS))
- {
- temp += VOL_ENUM_POS; /* behind special name */
- volume = atoi(temp); /* number is following */
- temp = strchr(temp, '/'); /* search for slash behind */
- if (temp != NULL)
- name = temp; /* use the part behind the volume */
- else
- name = "/"; /* else this must be the root dir */
- }
-
- strlcpy(namecopy, name, MAX_PATH);
-
- return volume;
-}
-#endif /* #ifdef HAVE_MULTIVOLUME */
-
-
#ifdef HAVE_HOTSWAP
// release all dir handles on a given volume "by force", to avoid leaks
int release_dirs(int volume)