problem with patch

Date view Thread view Subject view Author view

From: Archie Cobbs (archie@whistle.com)
Date: Thu Oct 15 1998 - 20:52:08 EDT


Tim,
The patch below (which was recently committed after 1.0b2) causes
my SableCC parser compilation to strangely fail. I fear that the
patch is not correct somehow, but I have no idea how (haven't
had time to investigate the problem yet).

The symptom is that SableCC dies after running OK for a while.
Right when it dies, it outputs "null". Perhaps some kind of
exception handling problem?

I compiled kaffe from the CVS sources as of 5:00 today, and
using it SableCC dies. When I removed this patch (ie, patch -R)
and tried again, it started working again.

-Archie

PS I've found running SableCC to be a good test of the JVM :-)

___________________________________________________________________________
Archie Cobbs * Whistle Communications, Inc. * http://www.whistle.com

Index: kaffe/kaffevm/object.c
===================================================================
RCS file: /cvs/mod/net/kaffe/kaffe/kaffevm/object.c,v
retrieving revision 1.1.1.2.4.1
retrieving revision 1.1.1.2.4.2
diff -u -r1.1.1.2.4.1 -r1.1.1.2.4.2
--- object.c 1998/10/07 01:57:26 1.1.1.2.4.1
+++ object.c 1998/10/16 00:04:38 1.1.1.2.4.2
@@ -113,7 +113,7 @@
         int i;
         
         obj = newArray(CLASS_ELEMENT_TYPE(clazz), dims[0]);
- if (dims[1] > 0) {
+ if (dims[1] >= 0) {
                 array = OBJARRAY_DATA(obj);
                 for (i = 0; i < dims[0]; i++) {
                         array[i] = newMultiArray(CLASS_ELEMENT_TYPE(clazz), &dims[1]);
Index: kaffe/kaffevm/soft.c
===================================================================
RCS file: /cvs/mod/net/kaffe/kaffe/kaffevm/soft.c,v
retrieving revision 1.1.1.2.4.3
retrieving revision 1.1.1.2.4.4
diff -u -r1.1.1.2.4.3 -r1.1.1.2.4.4
--- soft.c 1998/10/07 01:57:27 1.1.1.2.4.3
+++ soft.c 1998/10/16 00:04:38 1.1.1.2.4.4
@@ -128,7 +128,7 @@
                 }
                 arraydims[i] = arg;
         }
- arraydims[i] = 0;
+ arraydims[i] = -1;
 
         /* Mmm, okay now build the array using the wonders of recursion */
         obj = newMultiArray(class, arraydims);


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 19:57:00 EDT