diff options
Diffstat (limited to 'firmware/common/file.c')
-rw-r--r-- | firmware/common/file.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/firmware/common/file.c b/firmware/common/file.c index 81b5a194c0..6714b9982c 100644 --- a/firmware/common/file.c +++ b/firmware/common/file.c | |||
@@ -132,7 +132,8 @@ int open(const char* pathname, int flags) | |||
132 | /* scan dir for name */ | 132 | /* scan dir for name */ |
133 | while ((entry = readdir(dir))) { | 133 | while ((entry = readdir(dir))) { |
134 | if ( !strcasecmp(name, entry->d_name) ) { | 134 | if ( !strcasecmp(name, entry->d_name) ) { |
135 | fat_open(entry->startcluster, | 135 | fat_open(IF_MV2(dir->fatdir.file.volume,) |
136 | entry->startcluster, | ||
136 | &(file->fatfile), | 137 | &(file->fatfile), |
137 | &(dir->fatdir)); | 138 | &(dir->fatdir)); |
138 | file->size = file->trunc ? 0 : entry->size; | 139 | file->size = file->trunc ? 0 : entry->size; |