Author: remm Date: Mon Mar 12 07:34:39 2007 New Revision: 517231 URL: http://svn.apache.org/viewvc?view=rev&rev=517231 Log: - Cleanup of the message that is displayed.
Modified: tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/DefaultErrorHandler.java Modified: tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/DefaultErrorHandler.java URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/DefaultErrorHandler.java?view=diff&rev=517231&r1=517230&r2=517231 ============================================================================== --- tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/DefaultErrorHandler.java (original) +++ tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/DefaultErrorHandler.java Mon Mar 12 07:34:39 2007 @@ -67,17 +67,25 @@ StringBuffer buf = new StringBuffer(); for (int i=0; i < details.length; i++) { - args = new Object[] { - new Integer(details[i].getJspBeginLineNumber()), - details[i].getJspFileName() }; - buf.append("\n\n"); - buf.append(Localizer.getMessage("jsp.error.single.line.number", - args)); - buf.append("\n"); - buf.append(details[i].getErrorMessage()); if (details[i].getJspBeginLineNumber() >= 0) { + args = new Object[] { + new Integer(details[i].getJspBeginLineNumber()), + details[i].getJspFileName() }; + buf.append("\n\n"); + buf.append(Localizer.getMessage("jsp.error.single.line.number", + args)); + buf.append("\n"); + buf.append(details[i].getErrorMessage()); buf.append("\n"); buf.append(details[i].getJspExtract()); + } else { + args = new Object[] { + new Integer(details[i].getJavaLineNumber()) }; + buf.append("\n\n"); + buf.append(Localizer.getMessage("jsp.error.java.line.number", + args)); + buf.append("\n"); + buf.append(details[i].getErrorMessage()); } } buf.append("\n\nStacktrace:"); --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]