From dev-return-62973-apmail-ant-dev-archive=ant.apache.org@ant.apache.org Fri Jan 14 10:09:30 2005 Return-Path: Delivered-To: apmail-ant-dev-archive@www.apache.org Received: (qmail 29906 invoked from network); 14 Jan 2005 10:09:29 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 14 Jan 2005 10:09:29 -0000 Received: (qmail 64877 invoked by uid 500); 14 Jan 2005 10:09:27 -0000 Delivered-To: apmail-ant-dev-archive@ant.apache.org Received: (qmail 64573 invoked by uid 500); 14 Jan 2005 10:09:25 -0000 Mailing-List: contact dev-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Ant Developers List" Reply-To: "Ant Developers List" Delivered-To: mailing list dev@ant.apache.org Received: (qmail 64462 invoked by uid 500); 14 Jan 2005 10:09:25 -0000 Received: (qmail 64453 invoked by uid 99); 14 Jan 2005 10:09:25 -0000 X-ASF-Spam-Status: No, hits=-9.8 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from minotaur.apache.org (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.28) with SMTP; Fri, 14 Jan 2005 02:09:24 -0800 Received: (qmail 29766 invoked by uid 1146); 14 Jan 2005 10:09:23 -0000 Date: 14 Jan 2005 10:09:23 -0000 Message-ID: <20050114100923.29765.qmail@minotaur.apache.org> From: bodewig@apache.org To: ant-cvs@apache.org Subject: cvs commit: ant/src/main/org/apache/tools/ant Project.java X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N bodewig 2005/01/14 02:09:23 Modified: src/main/org/apache/tools/ant Project.java Log: Silently ignore messages being written to System.err/out while a Listener is processing a different message Revision Changes Path 1.183 +15 -5 ant/src/main/org/apache/tools/ant/Project.java Index: Project.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/Project.java,v retrieving revision 1.182 retrieving revision 1.183 diff -u -r1.182 -r1.183 --- Project.java 10 Jan 2005 23:44:57 -0000 1.182 +++ Project.java 14 Jan 2005 10:09:23 -0000 1.183 @@ -1982,10 +1982,20 @@ } synchronized (this) { if (loggingMessage) { - throw new BuildException("Listener attempted to access " - + (priority == MSG_ERR ? "System.err" : "System.out") - + " with message [" + message - + "] - infinite loop terminated"); + /* + * One of the Listeners has attempted to access + * System.err or System.out. + * + * We used to throw an exception in this case, but + * sometimes Listeners can't prevent it(like our own + * Log4jListener which invokes getLogger() which in + * turn wants to write to the console). + * + * @see http://marc.theaimsgroup.com/?t=110538624200006&r=1&w=2 + * + * We now (Ant 1.7 and 1.6.3) simply swallow the message. + */ + return; } try { loggingMessage = true; --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org For additional commands, e-mail: dev-help@ant.apache.org