View | Details | Raw Unified | Return to bug 62329
Collapse All | Expand All

(-)java/org/apache/catalina/webresources/AbstractArchiveResourceSet.java (-5 / +3 lines)
Lines 136-147 Link Here
136
                if (name.length() > pathInJar.length() &&
136
                if (name.length() > pathInJar.length() &&
137
                        name.startsWith(pathInJar)) {
137
                        name.startsWith(pathInJar)) {
138
                    int nextSlash = name.indexOf('/', pathInJar.length());
138
                    int nextSlash = name.indexOf('/', pathInJar.length());
139
                    if (nextSlash == -1 || nextSlash == name.length() - 1) {
139
                    if (nextSlash != -1 && nextSlash != name.length() - 1) {
140
                        if (name.startsWith(pathInJar)) {
140
                        name = name.substring(0, nextSlash + 1);
141
                            result.add(webAppMount + '/' +
142
                                    name.substring(getInternalPath().length()));
143
                        }
144
                    }
141
                    }
142
                    result.add(webAppMount + '/' + name.substring(getInternalPath().length()));
145
                }
143
                }
146
            }
144
            }
147
        } else {
145
        } else {

Return to bug 62329