bodewig     2005/01/14 02:12:31

  Modified:    src/main/org/apache/tools/ant Tag: ANT_16_BRANCH
                        Project.java
  Log:
  merge
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.154.2.15 +16 -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.154.2.14
  retrieving revision 1.154.2.15
  diff -u -r1.154.2.14 -r1.154.2.15
  --- Project.java      14 Dec 2004 23:48:00 -0000      1.154.2.14
  +++ Project.java      14 Jan 2005 10:12:31 -0000      1.154.2.15
  @@ -1,5 +1,5 @@
   /*
  - * Copyright  2000-2004 The Apache Software Foundation
  + * Copyright  2000-2005 The Apache Software Foundation
    *
    *  Licensed under the Apache License, Version 2.0 (the "License");
    *  you may not use this file except in compliance with the License.
  @@ -2013,9 +2013,20 @@
           }
           synchronized (this) {
               if (loggingMessage) {
  -                throw new BuildException("Listener attempted to access "
  -                    + (priority == MSG_ERR ? "System.err" : "System.out")
  -                    + " - 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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to