sdeboy      2004/12/19 15:54:07

  Modified:    src/java/org/apache/log4j/varia LocationInfoFilter.java
  Log:
  Had to set the fully qualified class to Category so that parsing would 
correctly find the source class in the exception
  
  Revision  Changes    Path
  1.2       +4 -1      
logging-log4j/src/java/org/apache/log4j/varia/LocationInfoFilter.java
  
  Index: LocationInfoFilter.java
  ===================================================================
  RCS file: 
/home/cvs/logging-log4j/src/java/org/apache/log4j/varia/LocationInfoFilter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LocationInfoFilter.java   19 Dec 2004 18:01:07 -0000      1.1
  +++ LocationInfoFilter.java   19 Dec 2004 23:54:07 -0000      1.2
  @@ -39,6 +39,9 @@
     boolean convertInFixToPostFix = true;
     String expression;
     Rule expressionRule;
  +  //HACK: Category is the last of the internal layers - pass this in as the 
class name
  +  //in order for parsing to work correctly
  +  private String className = "org.apache.log4j.Category";
   
     public void activateOptions() {
       expressionRule =
  @@ -74,7 +77,7 @@
       if (!event.locationInformationExists()) {
         if (expressionRule.evaluate(event)) {
              Throwable t = new Exception();
  -           event.setLocationInformation(new LocationInfo(t, 
getClass().getName()));
  +           event.setLocationInformation(new LocationInfo(t, className));
         }
       }
       return Filter.NEUTRAL;
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to