Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8267553

Extra JavaThread assignment in ClassLoader::create_class_path_entry()

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 17
    • 17
    • hotspot
    • None
    • b24

      ClassPathEntry* ClassLoader::create_class_path_entry(JavaThread* current,
                                                           const char *path, const struct stat* st,
                                                           bool is_boot_append,
                                                           bool from_class_path_attr) {
        JavaThread* thread = current->as_Java_thread();

      The first arg is already a JavaThread. The "JavaThread* thread" local variable is unnecessary. Subsequent statements using "thread" could just simply use "current" instead.

            dholmes David Holmes
            ccheung Calvin Cheung
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: