Skip to content

Avoid trying to load classes from the default package (fixes #21)#22

Merged
cpw merged 1 commit intoMcModLauncher:mainfrom
Su5eD:fix/unpackged
Jan 23, 2022
Merged

Avoid trying to load classes from the default package (fixes #21)#22
cpw merged 1 commit intoMcModLauncher:mainfrom
Su5eD:fix/unpackged

Conversation

@Su5eD
Copy link
Copy Markdown
Member

@Su5eD Su5eD commented Jan 20, 2022

As described in #21, the ModuleClassLoader throws an unexpected StringIndexOutOfBoundsException exception when trying to load a class from the default package.

This PR adds an if statement to ignore package-less classes, restoring expected behavior throwing a ClassNotFoundException.

@sciwhiz12 sciwhiz12 added the bug Something isn't working label Jan 20, 2022
@sciwhiz12 sciwhiz12 requested a review from a team January 20, 2022 17:14
Copy link
Copy Markdown
Member

@cpw cpw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@cpw cpw merged commit 375c6b5 into McModLauncher:main Jan 23, 2022
@Su5eD Su5eD deleted the fix/unpackged branch April 2, 2022 11:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants