Extra JavaThread assignment in ClassLoader::create_class_path_entry()

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Fixed
    • Priority: P4
    • 17
    • Affects Version/s: 17
    • Component/s: 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.

            Assignee:
            David Holmes
            Reporter:
            Calvin Cheung (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: