On Tue, 2005-11-08 at 18:30 -0700, Tom Tromey wrote:
> Actually, this field is still required for serialization.
Fixed.
2005-11-09 Anthony Balkissoon <[EMAIL PROTECTED]>
* java/awt/event/InvocationEvent.java:
(exception): Replaced this field (removed yesterday) because it is
needed for serialization.
(dispatch): Save thrown exception.
(getException): Directly return exception, no need to cast throwable.
--Tony
Index: java/awt/event/InvocationEvent.java
===================================================================
RCS file: /cvsroot/classpath/classpath/java/awt/event/InvocationEvent.java,v
retrieving revision 1.11
diff -u -r1.11 InvocationEvent.java
--- java/awt/event/InvocationEvent.java 8 Nov 2005 20:51:39 -0000 1.11
+++ java/awt/event/InvocationEvent.java 9 Nov 2005 19:21:58 -0000
@@ -98,6 +98,15 @@
protected boolean catchExceptions;
/**
+ * This is the caught exception thrown in the <code>run()</code> method. It
+ * is null if exceptions are ignored, the run method hasn't completed, or
+ * there were no exceptions.
+ *
+ * @serial the caught exception, if any
+ */
+ private Exception exception;
+
+ /**
* This is the caught Throwable thrown in the <code>run()</code> method.
* It is null if throwables are ignored, the run method hasn't completed,
* or there were no throwables thrown.
@@ -184,6 +193,8 @@
catch (Throwable t)
{
throwable = t;
+ if (t instanceof Exception)
+ exception = (Exception)t;
}
else
runnable.run();
@@ -205,9 +216,7 @@
*/
public Exception getException()
{
- if (throwable == null || !(throwable instanceof Exception))
- return null;
- return (Exception) throwable;
+ return exception;
}
/**
_______________________________________________
Classpath-patches mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/classpath-patches