... | ... |
@@ -130,7 +130,12 @@ file_write(void *src, Uint16 len, Uint8 flags) |
130 | 130 |
Uint16 |
131 | 131 |
file_stat(void *dest, Uint16 len) |
132 | 132 |
{ |
133 |
- return get_entry(dest, len, current_filename, current_filename, 0); |
|
133 |
+ char *basename = strrchr(current_filename, '/'); |
|
134 |
+ if(basename != NULL) |
|
135 |
+ ++basename; |
|
136 |
+ else |
|
137 |
+ basename = current_filename; |
|
138 |
+ return get_entry(dest, len, current_filename, basename, 0); |
|
134 | 139 |
} |
135 | 140 |
|
136 | 141 |
Uint16 |