* gjavah.c (throwable_p): Allocate 1 more byte for string.
authorMark Wielaard <mark@klomp.org>
Sat, 1 Feb 2003 01:31:31 +0000 (01:31 +0000)
committerMark Wielaard <mark@gcc.gnu.org>
Sat, 1 Feb 2003 01:31:31 +0000 (01:31 +0000)
From-SVN: r62228

gcc/java/ChangeLog
gcc/java/gjavah.c

index 062c368bea4ab4203dcf138bd6c23bac63c5d37f..bb360c0afc05c66beb054563c4f05f73f1537631 100644 (file)
@@ -1,3 +1,7 @@
+2003-01-31  Mark Wielaard  <mark@klomp.org>
+
+       * gjavah.c (throwable_p): Allocate 1 more byte for string.
+
 2003-01-31  Nathan Sidwell  <nathan@codesourcery.com>
 
        * class.c (make_class): Use BINFO_ELTS.
index 7c7e3685d5d1f3a36a8538863478588a4e10d619..42f33276edc4ca2e7822d092a6018d3d14010e5c 100644 (file)
@@ -1119,7 +1119,7 @@ throwable_p (const unsigned char *clname)
 
   for (length = 0; clname[length] != ';' && clname[length] != '\0'; ++length)
     ;
-  current = ALLOC (length);
+  current = ALLOC (length + 1);
   for (i = 0; i < length; ++i)
     current[i] = clname[i] == '/' ? '.' : clname[i];
   current[length] = '\0';