Minor clean up and bug fix.
authorAnthony Green <green@cygnus.com>
Sat, 26 Feb 2000 21:12:54 +0000 (21:12 +0000)
committerAnthony Green <green@gcc.gnu.org>
Sat, 26 Feb 2000 21:12:54 +0000 (21:12 +0000)
From-SVN: r32196

libjava/ChangeLog
libjava/gnu/gcj/io/MimeTypes.java
libjava/java/net/URLConnection.java
libjava/jni.cc

index e2c84d29dd630baa4f31482569cb0f0c00dfd2e6..ccf334665d1f3df23fc58f502183a4315ff26103 100644 (file)
@@ -1,3 +1,12 @@
+2000-02-26  Anthony Green  <green@cygnus.com>
+
+       * gnu/gcj/io/MimeTypes.java: Test for null.
+
+       * jni.cc (_Jv_JNI_AttachCurrentThread): Minor cleanup.
+       (JNI_GetCreatedJavaVMs): Remove compiler warning.
+
+       * java/net/URLConnection.java: Update copyright notice.
+
 2000-02-25  Tom Tromey  <tromey@cygnus.com>
 
        * jni.cc (_Jv_JNI_RegisterNatives): Conditionalize body on
index 36d3eb86f1463e031a1f75a44e09b22ac8f2a325..f4a114bf9e89222f10cb1fc343fc5f25e117f303 100644 (file)
@@ -36,7 +36,7 @@ public class MimeTypes
                  {
                    // Read the next extension
                    String e = tokenizer.nextToken ();
-                   if (! e.startsWith ("#"))
+                   if ((e != null) && (! e.startsWith ("#")))
                      table.put (e, t);
                    else
                      break;
index 60cfd76714f6300720d9d911ae95dfc4bf504e21..8ba61d1afcda7679293a5629e4e18b4d3aadbad0 100644 (file)
@@ -1,7 +1,7 @@
 // URLConnection.java - Superclass of all communications links between
 //                     an application and a URL.
 
-/* Copyright (C) 1999  Red Hat, Inc.
+/* Copyright (C) 1999, 2000  Red Hat, Inc.
 
    This file is part of libgcj.
 
index 92dbf3fb26e055f0746e8be9e7b9a27bd7a8153f..3eca405757e200917dca45546474ce7c29b847e5 100644 (file)
@@ -1545,8 +1545,7 @@ _Jv_JNI_AttachCurrentThread (JavaVM *, jstring name, void **penv, void *args)
   // have been called simply to set the new JNIEnv.
   if (_Jv_ThreadCurrent () == NULL)
     {
-      java::lang::Thread *t = new gnu::gcj::jni::NativeThread (group, name);
-      t = t;                   // Avoid compiler warning.  Eww.
+      (void) new gnu::gcj::jni::NativeThread (group, name);
     }
   _Jv_SetCurrentJNIEnv (env);
 
@@ -1707,7 +1706,7 @@ JNI_CreateJavaVM (JavaVM **vm, void **penv, void *args)
 }
 
 jint
-JNI_GetCreatedJavaVMs (JavaVM **vm_buffer, jsize buf_len, jsize *n_vms)
+JNI_GetCreatedJavaVMs (JavaVM **vm_buffer, jsize /* buf_len */, jsize *n_vms)
 {
   JvAssert (buf_len > 0);
   // We only support a single VM.