From 2d25461bcbce43be17becfe8d53d14d17a233c6c Mon Sep 17 00:00:00 2001 From: Thomas Fitzsimmons Date: Mon, 29 May 2006 22:04:13 +0000 Subject: natThread.cc (countStackFrames): Do not throw UnsupportedOperationException. 2006-05-29 Thomas Fitzsimmons * java/lang/natThread.cc (countStackFrames): Do not throw UnsupportedOperationException. (resume): Likewise. (stop): Likewise. (suspend): Likewise. From-SVN: r114218 --- libjava/java/lang/natThread.cc | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'libjava/java') diff --git a/libjava/java/lang/natThread.cc b/libjava/java/lang/natThread.cc index 2879df8..9984142 100644 --- a/libjava/java/lang/natThread.cc +++ b/libjava/java/lang/natThread.cc @@ -20,7 +20,6 @@ details. */ #include #include #include -#include #include #include #include @@ -91,8 +90,10 @@ jint java::lang::Thread::countStackFrames (void) { // NOTE: This is deprecated in JDK 1.2. - throw new UnsupportedOperationException - (JvNewStringLatin1 ("Thread.countStackFrames unimplemented")); + + // Old applets still call this method. Rather than throwing + // UnsupportedOperationException we simply fail silently. + return 0; } @@ -150,8 +151,9 @@ void java::lang::Thread::resume (void) { checkAccess (); - throw new UnsupportedOperationException - (JvNewStringLatin1 ("Thread.resume unimplemented")); + + // Old applets still call this method. Rather than throwing + // UnsupportedOperationException we simply fail silently. } void @@ -335,16 +337,18 @@ void java::lang::Thread::stop (java::lang::Throwable *) { checkAccess (); - throw new UnsupportedOperationException - (JvNewStringLatin1 ("Thread.stop unimplemented")); + + // Old applets still call this method. Rather than throwing + // UnsupportedOperationException we simply fail silently. } void java::lang::Thread::suspend (void) { checkAccess (); - throw new UnsupportedOperationException - (JvNewStringLatin1 ("Thread.suspend unimplemented")); + + // Old applets still call this method. Rather than throwing + // UnsupportedOperationException we simply fail silently. } static int nextThreadNumber = 0; -- cgit v1.1