Skip to content

Conversation

@Big-Iron-Cheems
Copy link
Collaborator

Type of change

  • Bug fix
  • New feature

Description

Replace the Reflections lib with Classgraph, as the former is unmaintained.
PacketUtilsUtil was rewritten such that the file is written all at once, leveraging Java NIO utils.
Order of the packets is still the same as before.

Related issues

None.

How Has This Been Tested?

Loading several 1.21.10 addons and running PacketUtilsUtil.

Checklist:

  • My code follows the style guidelines of this project.
  • I have added comments to my code in more complex areas.
  • I have tested the code in both development and production environments.

TODO: see if the code can be improved further
NOTE: var is used to suppress a comp-time warning of `toList()`
Removes the intermediate Comparator, StringBuilder and packets list
@Big-Iron-Cheems
Copy link
Collaborator Author

Possible PR blocker.

While this worked fine on my Windows machine, it causes a crash on my Linux one.
A double free in meteordevelopment.meteorclient.gui.renderer.packer.TexturePacker.Image#free seems to trigger when trying to load Catpuccin-Addon.

Attached are, in the following order:

I believe this was a latent bug that Classgraph made easier to trigger, but verification is needed.
Considering this PR doesn't change this code, it could be possible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant