Path fixup in the zipreader (necessary with my adapter/zip/build combination?)

svn-id: r24128
This commit is contained in:
Bertrand Augereau 2006-10-05 20:27:09 +00:00
parent ac7651b273
commit b01275d8c5

View File

@ -215,6 +215,9 @@ void ZipFile::changeToRoot() {
void ZipFile::changeDirectory(char* dir) {
// consolePrintf("Current dir now '%s'\n", dir);
strcpy(_directory, dir);
size_t l = strlen(_directory);
if (l && (_directory[l-1] == '/' ))
_directory[l-1] = '\0';
}
ZipFile::~ZipFile() {