This issue is mentioned in Bugzilla: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23221
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15939 > -----Original Message----- > From: Sullivan, Sean C - MWT > Sent: Friday, November 14, 2003 2:52 PM > To: '[EMAIL PROTECTED]' > Subject: SMTPAppender, throwable string representation, Log4j 1.2.8 > > > I am using: > > - Sun J2SE 1.3.1.06 > - Jakarta Log4j 1.2.8 > - SMTPAppender with PatternLayout > > When the SMTPAppender sends an email message, the stack trace > is formatted differently than I would expect. > > The entire stack trace is concatenated onto a single line. > > I was expecting the stack trace to be on multiple lines. > > I studied the source code for SMTPAppender. This is what I found: > > // > // source file: src/java/org/apache/log4j/net/SMTPAppender.java > // > protected void sendBuffer() { > > // ... > if(layout.ignoresThrowable()) { > String[] s = event.getThrowableStrRep(); > if (s != null) { > for(int j = 0; j < s.length; j++) { > sbuf.append(s[j]); > } > } > } > > // ... > } > > You'll notice that the inner for loop does not append newline > characters. > > It would be helpful if the loop appended a new line character: > > for(int j = 0; j < s.length; j++) { > sbuf.append(s[j]); > sbuf.append("\n"); > } > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]