Print this page


Split Close
Expand all
Collapse all
          --- old/src/share/vm/runtime/vframe.cpp
          +++ new/src/share/vm/runtime/vframe.cpp
   1    1  /*
   2      - * Copyright 1997-2009 Sun Microsystems, Inc.  All Rights Reserved.
        2 + * Copyright 1997-2010 Sun Microsystems, Inc.  All Rights Reserved.
   3    3   * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4    4   *
   5    5   * This code is free software; you can redistribute it and/or modify it
   6    6   * under the terms of the GNU General Public License version 2 only, as
   7    7   * published by the Free Software Foundation.
   8    8   *
   9    9   * This code is distributed in the hope that it will be useful, but WITHOUT
  10   10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11   11   * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12   12   * version 2 for more details (a copy is included in the LICENSE file that
↓ open down ↓ 412 lines elided ↑ open up ↑
 425  425  void vframeStreamCommon::security_get_caller_frame(int depth) {
 426  426    bool use_new_reflection = JDK_Version::is_gte_jdk14x_version() && UseNewReflection;
 427  427  
 428  428    while (!at_end()) {
 429  429      if (Universe::reflect_invoke_cache()->is_same_method(method())) {
 430  430        // This is Method.invoke() -- skip it
 431  431      } else if (use_new_reflection &&
 432  432                Klass::cast(method()->method_holder())
 433  433                   ->is_subclass_of(SystemDictionary::reflect_MethodAccessorImpl_klass())) {
 434  434        // This is an auxilary frame -- skip it
      435 +    } else if (method()->is_method_handle_adapter()) {
      436 +      // This is an internal adapter frame from the MethodHandleCompiler -- skip it
 435  437      } else {
 436  438        // This is non-excluded frame, we need to count it against the depth
 437  439        if (depth-- <= 0) {
 438  440          // we have reached the desired depth, we are done
 439  441          break;
 440  442        }
 441  443      }
 442  444      if (method()->is_prefixed_native()) {
 443  445        skip_prefixed_method_and_wrappers();
 444  446      } else {
↓ open down ↓ 216 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX