< prev index next >

src/share/vm/memory/blockOffsetTable.cpp

Print this page
rev 7793 : 8073315: Enable gcc -Wtype-limits and fix upcoming issues.

@@ -791,7 +791,7 @@
   _array->set_offset_array(bottom_index, 0);
 }
 
 size_t BlockOffsetArrayContigSpace::last_active_index() const {
   size_t result = _next_offset_index - 1;
-  return result >= 0 ? result : 0;
+  return ((intptr_t)result) >= 0 ? result : 0;
 }
< prev index next >