You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Renamed normalizeEntryName to stripLeadingAndTrailingSlashes for better clarity.
Enhanced the normalization logic to handle multiple consecutive leading or trailing slashes. Now, any degenerate entries with multiple slashes are properly stripped to ensure consistent and safe entry paths.
Removed redundant checks for leading or trailing slashes after
normalization. -> Based on Norman Rzepka's suggestion.
Since the normalization process now handles all cases, there's no need for further slash-stripping.
Updated zip entry processing logic to:
Continue using the isDirectory() flag and directoryToChildrenDirectoriesIndex for directory entries.
Unified root directory handling, creating indices, no recursion.
"Directory entry '{0}' did start with '/' not removed by normalizeEntryName()",
124
-
e.getName());
125
-
}
110
+
// In some zip files entries may have leading or trailing slashes, we want to ignore those for consistent indexing
111
+
// Trailing shashes are common for directory entries, but since we have dedicated directoryToChildrenDirectoriesIndex we strip those and rely on the isDirectory() flag to determine if an entry is a directory or file
0 commit comments