https://issues.apache.org/bugzilla/show_bug.cgi?id=52772
Bug #: 52772 Summary: JspC : checking uriRoot option validness Product: Tomcat 7 Version: trunk Platform: PC OS/Version: Linux Status: NEW Severity: trivial Priority: P2 Component: Jasper AssignedTo: dev@tomcat.apache.org ReportedBy: bluewolf.ch...@gmail.com Classification: Unclassified In org.apache.jasper.JspC#execute() method, if uriRoot is not null, it scans all jsp files under uriRoot, and then checks if uriRoot is a directory. It should be more desirable to check if uriRoot is a directory or not first and then scanning it. Here are my suggestion. if (uriRoot == null) { throw new JasperException( Localizer.getMessage("jsp.error.jspc.no_uriroot")); } File uriRootF = new File(uriRoot); if (!uriRootF.exists() || !uriRootF.isDirectory()) { throw new JasperException( Localizer.getMessage("jsp.error.jspc.uriroot_not_dir")); } if( context==null ) { initServletContext(); } // No explicit pages, we'll process all .jsp in the webapp if (pages.size() == 0) { scanFiles(uriRootF); } -- Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- 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