DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=40502>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ· INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=40502 Summary: SyslogAppender assumes all lines start with tab Product: Log4j Version: 1.2 Platform: Other OS/Version: other Status: NEW Severity: normal Priority: P2 Component: Appender AssignedTo: [email protected] ReportedBy: [EMAIL PROTECTED] The SyslogAppender assumes each line of output starts with a tab and replaces it with spaces. If the line doesn't start with a tab, the first character of the line is lost. If the line is empty, the appender will get an exception. The patch to fix this problem is: *** SyslogAppender.java.orig Wed Sep 13 15:53:09 2006 --- SyslogAppender.java Wed Sep 13 15:53:05 2006 *************** *** 260,266 **** if(len > 0) { sqw.write(s[0]); for(int i = 1; i < len; i++) { ! sqw.write(TAB+s[i].substring(1)); } } } --- 260,274 ---- if(len > 0) { sqw.write(s[0]); for(int i = 1; i < len; i++) { ! if (s[i].length() > 0) { ! if (s[i].charAt(0) == '\t') { ! sqw.write(TAB+s[i].substring(1)); ! } else { ! sqw.write(TAB+s[i]); ! } ! } else { ! sqw.write(s[i]); ! } } } } -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
