# HG changeset patch # User sspitsyn # Date 1431992566 25200 # Node ID e8641f96a82b08819675de01ec77055db38a97e4 # Parent deee942af1253253ad0adfedea547bc34ad42e72 8079644: memory stomping error with ResourceManagement and TestAgentStress.java Summary: the cached class file structure must be deallocated instead of the cached class file bytes Reviewed-by: coleenp, sla diff -r deee942af125 -r e8641f96a82b hotspot/src/share/vm/prims/jvmtiRedefineClasses.cpp --- a/hotspot/src/share/vm/prims/jvmtiRedefineClasses.cpp Sat May 16 13:19:11 2015 -0700 +++ b/hotspot/src/share/vm/prims/jvmtiRedefineClasses.cpp Mon May 18 16:42:46 2015 -0700 @@ -3993,8 +3993,8 @@ the_class->get_cached_class_file_bytes()) { // The same class can be present twice in the scratch classes list or there // are multiple concurrent RetransformClasses calls on different threads. - // In such cases we have to deallocate scratch_class cached_class_file_bytes. - os::free(scratch_class->get_cached_class_file_bytes()); + // In such cases we have to deallocate scratch_class cached_class_file. + os::free(scratch_class->get_cached_class_file()); } // NULL out in scratch class to not delete twice. The class to be redefined