This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

FYI: java.util.Timer patch


Hi,

I am checking in this fix which prevents the Timer to throw a
NullPointerException after being canceled as pointed out by Shuhua Zhang
in a private mail.

2002-03-03 Mark Wielaard <mark@klomp.org>

        * java/util/Timer (TaskQueue.stop): set elements to zero.

Cheers,

Mark
Index: java/util/Timer.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/util/Timer.java,v
retrieving revision 1.6
diff -u -r1.6 Timer.java
--- Timer.java	2002/01/22 22:40:39	1.6
+++ Timer.java	2002/03/03 10:58:30
@@ -293,6 +293,7 @@
     public synchronized void stop()
     {
       this.heap = null;
+      this.elements = 0;
       this.notify();
     }
 

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]