Fixed enumerations that end with '/'.
authorRyan C. Gordon <icculus@icculus.org>
Tue, 23 Jul 2002 17:52:56 +0000
changeset 368 29a96046cf23
parent 367 2869fcc68432
child 369 7c1ede6201cc
Fixed enumerations that end with '/'.
archivers/zip.c
--- a/archivers/zip.c	Tue Jul 23 17:52:36 2002 +0000
+++ b/archivers/zip.c	Tue Jul 23 17:52:56 2002 +0000
@@ -1258,6 +1258,9 @@
     LinkedStringList *retval = NULL, *p = NULL;
     PHYSFS_uint32 dlen = strlen(dirname);
 
+    if (dirname[dlen - 1] == '/')
+        dlen--;
+
     i = zip_find_start_of_dir(info, dirname, 0);
     BAIL_IF_MACRO(i == -1, ERR_NO_SUCH_FILE, NULL);