On Mon, 2002-10-14 at 14:42, Jerome Lacoste (Frisurf) wrote:
> Proposed patch attached. Not tested...

and obviously not looked at neither: I made the diff the other way
around. Sorry for that. 

Correct intended patch attached.

Jerome
--- CategoryStream.java	2002-10-14 14:39:52.000000000 +0200
+++ src/main/org/jboss/logging/util/CategoryStream.java	2002-10-14 14:32:20.000000000 +0200
@@ -128,11 +128,14 @@
       if (len != 0) {
          String msg = new String(b, off, len);
 
-         if (TRACE) {
-            category.log(priority, msg, new Throwable());
-         }
-         else {
-            category.log(priority, msg);
+         synchronized (category)
+         {
+             if (TRACE) {
+                category.log(priority, msg, new Throwable());
+             }
+             else {
+                category.log(priority, msg);
+             }
          }
       }
       inWrite = false;

Reply via email to