https://issues.apache.org/bugzilla/show_bug.cgi?id=55109
Bug ID: 55109 Summary: Wasted work in "WebdavServlet.isLocked" Product: Tomcat 7 Version: 7.0.41 Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P2 Component: Catalina Assignee: dev@tomcat.apache.org Reporter: nist...@illinois.edu Created attachment 30449 --> https://issues.apache.org/bugzilla/attachment.cgi?id=30449&action=edit patch The problem appears in version 7.0.41 and in revision 1493861. I attached a two-line patch that fixes it. In method "WebdavServlet.isLocked", the two loops over "tokenList" should break immediately after "tokenMatch" is set to "true". All the iterations after "tokenMatch" is set to "true" do not perform any useful work, at best they just set "tokenMatch" again to "true". Method "startInternal" in class "StandardHost" has a similar loop (over "valves"), and this loop breaks immediately after "found" is set to "true", just like in the proposed patch. Other methods (e.g., "MapperListener.findDefaultHost", "CollectVisitor.checkSeen", "JspDocumentParser.processChars", "ParameterParser.isOneOf") also have similar loops with similar breaks, just like in the proposed patch. -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org