comparison src/share/vm/classfile/classFileParser.cpp @ 4755:2b3acb34791f

Merge
author dcubed
date Fri, 06 Jan 2012 16:18:29 -0800
parents 05de27e852c4 5b58979183f9
children f7c4174b33ba fc9d8850ab8b
comparison
equal deleted inserted replaced
4748:2ee4167627a3 4755:2b3acb34791f
2664 2664
2665 _has_finalizer = _has_empty_finalizer = _has_vanilla_constructor = false; 2665 _has_finalizer = _has_empty_finalizer = _has_vanilla_constructor = false;
2666 _max_bootstrap_specifier_index = -1; 2666 _max_bootstrap_specifier_index = -1;
2667 2667
2668 if (JvmtiExport::should_post_class_file_load_hook()) { 2668 if (JvmtiExport::should_post_class_file_load_hook()) {
2669 // Get the cached class file bytes (if any) from the 2669 // Get the cached class file bytes (if any) from the class that
2670 // class that is being redefined. 2670 // is being redefined or retransformed. We use jvmti_thread_state()
2671 JvmtiThreadState *state = JvmtiThreadState::state_for(jt); 2671 // instead of JvmtiThreadState::state_for(jt) so we don't allocate
2672 KlassHandle *h_class_being_redefined = 2672 // a JvmtiThreadState any earlier than necessary. This will help
2673 state->get_class_being_redefined(); 2673 // avoid the bug described by 7126851.
2674 if (h_class_being_redefined != NULL) { 2674 JvmtiThreadState *state = jt->jvmti_thread_state();
2675 instanceKlassHandle ikh_class_being_redefined = 2675 if (state != NULL) {
2676 instanceKlassHandle(THREAD, (*h_class_being_redefined)()); 2676 KlassHandle *h_class_being_redefined =
2677 cached_class_file_bytes = 2677 state->get_class_being_redefined();
2678 ikh_class_being_redefined->get_cached_class_file_bytes(); 2678 if (h_class_being_redefined != NULL) {
2679 cached_class_file_length = 2679 instanceKlassHandle ikh_class_being_redefined =
2680 ikh_class_being_redefined->get_cached_class_file_len(); 2680 instanceKlassHandle(THREAD, (*h_class_being_redefined)());
2681 cached_class_file_bytes =
2682 ikh_class_being_redefined->get_cached_class_file_bytes();
2683 cached_class_file_length =
2684 ikh_class_being_redefined->get_cached_class_file_len();
2685 }
2681 } 2686 }
2682 2687
2683 unsigned char* ptr = cfs->buffer(); 2688 unsigned char* ptr = cfs->buffer();
2684 unsigned char* end_ptr = cfs->buffer() + cfs->length(); 2689 unsigned char* end_ptr = cfs->buffer() + cfs->length();
2685 2690