[kaffe] CVS kaffe (rob): (verify.c:verify3()) Debugger prints out "done verifying whatever" regardless of success or failure.

Kaffe CVS cvs-commits at kaffe.org
Wed Aug 13 13:55:02 PDT 2003


PatchSet 3944 
Date: 2003/08/13 21:50:25
Author: rob
Branch: HEAD
Tag: (none) 
Log:
(verify.c:verify3()) Debugger prints out "done verifying whatever" regardless of success or failure.

Members: 
	ChangeLog:1.1546->1.1547 
	kaffe/kaffevm/verify.c:1.22->1.23 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.1546 kaffe/ChangeLog:1.1547
--- kaffe/ChangeLog:1.1546	Wed Aug 13 07:13:14 2003
+++ kaffe/ChangeLog	Wed Aug 13 13:50:25 2003
@@ -1,5 +1,13 @@
 2003-08-13  Rob Gonzalez <rob at kaffe.org>
 
+	* kaffe/kaffevm/verify.c
+	(verify3) Cosmetic return changes.  Use a success variable now
+	similar to classMethod.c:processClass().  Debugger should now,
+	in theory, print out a "done verifying class whatever" regardless
+	of success or failure.
+
+2003-08-13  Rob Gonzalez <rob at kaffe.org>
+
 	* kaffe/kaffevm/verify.h
 	(type_info) union expanded to support returnAddress type address
 	value.  Type.tinfo no longer used to hold return PC.
Index: kaffe/kaffe/kaffevm/verify.c
diff -u kaffe/kaffe/kaffevm/verify.c:1.22 kaffe/kaffe/kaffevm/verify.c:1.23
--- kaffe/kaffe/kaffevm/verify.c:1.22	Wed Aug 13 07:13:15 2003
+++ kaffe/kaffe/kaffevm/verify.c	Wed Aug 13 13:50:26 2003
@@ -949,8 +949,6 @@
 static Type* TDOUBLEARR = &verify_DOUBLEARR;
 
 
-#define IS_PRIMITIVE_TYPE(_TINFO) ((_TINFO)->tinfo & TINFO_PRIMITIVE)
-
 #define IS_PRIMITIVE_ARRAY(_TINFO) \
            (((_TINFO)->data.class) == TCHARARR->data.class  || ((_TINFO)->data.class) == TBYTEARR->data.class || \
 	    ((_TINFO)->data.class) == TSHORTARR->data.class || ((_TINFO)->data.class) == TINTARR->data.class  || \
@@ -1104,14 +1102,15 @@
 bool
 verify3(Hjava_lang_Class* class, errorInfo *einfo)
 {
-	int n;
+	uint32 n;
+	bool success = true;
 	Method* method;
 	
 	// see if verification is turned on, and whether the class we're about to verify requires verification
 	//
 	// NOTE: we don't skip interfaces here because an interface may contain a <clinit> method with bytecode
 	if (isTrustedClass(class)) {
-		return(true);
+		goto done;
 	}
 	
 	
@@ -1142,7 +1141,8 @@
 				postExceptionMessage(einfo, JAVA_LANG(ClassFormatError),
 						     "Method %s.%s has invalid signature, %s",
 						     CLASS_CNAME(class), METHOD_NAMED(method), METHOD_SIGD(method));
-				return(false);
+				success = false;
+				goto done;
 			}
 			else if (!verifyMethod(einfo, method)) {
 				if (einfo->type == 0) {
@@ -1150,14 +1150,16 @@
 							     "failure to verify method %s.%s ... reason unspecified",
 							     CLASS_CNAME(class), METHOD_NAMED(method));
 				}
-				return(false);
+				success = false;
+				goto done;
 			}
 		}
 	}
 	
 	
+ done:
 	DBG(VERIFY3, dprintf("\nDone Pass 3 Verifying Class \"%s\"\n", CLASS_CNAME(class)); );
-	return(true);
+	return success;
 }
 
 /*




More information about the kaffe mailing list