harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arc...@apache.org
Subject svn commit: r378941 - /incubator/harmony/enhanced/jchevm/libjc/heap.c
Date Sun, 19 Feb 2006 19:04:18 GMT
Author: archie
Date: Sun Feb 19 11:04:17 2006
New Revision: 378941

URL: http://svn.apache.org/viewcvs?rev=378941&view=rev
Log:
Fix invalid assertion.

Modified:
    incubator/harmony/enhanced/jchevm/libjc/heap.c

Modified: incubator/harmony/enhanced/jchevm/libjc/heap.c
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/jchevm/libjc/heap.c?rev=378941&r1=378940&r2=378941&view=diff
==============================================================================
--- incubator/harmony/enhanced/jchevm/libjc/heap.c (original)
+++ incubator/harmony/enhanced/jchevm/libjc/heap.c Sun Feb 19 11:04:17 2006
@@ -234,8 +234,8 @@
 	/* Sanity check */
 	_JC_ASSERT(bsi >= 0 && bsi < heap->num_sizes);
 	_JC_ASSERT(bs->hint == NULL
-	    || (((_jc_word)bs->hint & (_JC_PAGE_SIZE - 1)) % bs->size)
-	      == _JC_HEAP_BLOCK_OFFSET);
+	    || (((((_jc_word)bs->hint & (_JC_PAGE_SIZE - 1))
+	      - _JC_HEAP_BLOCK_OFFSET) % bs->size) == 0));
 	_JC_ASSERT(_JC_HEAP_SAME_PAGE(bs->hint,
 	    (char *)bs->hint + bs->size - 1));
 
@@ -597,8 +597,8 @@
 		_JC_ASSERT(((_jc_word)block_start & (_JC_PAGE_SIZE - 1))
 		    == _JC_HEAP_BLOCK_OFFSET);
 	} else {
-		_JC_ASSERT((((_jc_word)block_start & (_JC_PAGE_SIZE - 1))
-		    % block_size) == _JC_HEAP_BLOCK_OFFSET);
+		_JC_ASSERT(((((_jc_word)block_start & (_JC_PAGE_SIZE - 1))
+		    - _JC_HEAP_BLOCK_OFFSET) % block_size) == 0);
 	}
 }
 



Mime
View raw message