Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix crashes with CCL, TE tweaks #532

Merged
merged 3 commits into from
Jul 30, 2024
Merged

Conversation

jchung01
Copy link
Contributor

Fixed crash in CCL packet fix by removing extra release call. I think in theory having it is necessary, but it deallocates the packet too early if any mod calls any of the sendToXXX methods on the PacketCustom object multiple times. I couldn't really come up with a different way to ensure the packet is released before gc'ed in this particular case (without case-by-case modifications). I tested with -Dio.netty.leakDetection.level=paranoid and didn't seem to find any packet leaks from CCL related networking, so hopefully leaks are still prevented.

Also fixed crash with TE monoculture tweak change - forgot a mod check.

jchung01 added 2 commits July 29, 2024 18:28
- Was causing crashes in some cases (e.g. DE's `TileDataManager#detectAndSendChangesToListeners`)
- Don't really know a way to fix this if it causes packet leaks now...
Copy link

what-the-diff bot commented Jul 30, 2024

PR Summary

  • Enhanced Code Documentations
    Added explanatory comments to the 'UTPacketCustomRetainMixin' class, which specifically focuses on the 'utReleaseOriginal' method. This helps to make the code more readable and easier to understand.

  • Updated Import Statements
    Included the necessary import statement for the 'Loader' in the 'UTInsolatorExpansion' class. This is needed to ensure that all required libraries/modules are available for the program to function correctly.

  • Updated Method for Better Error Handling
    The 'getFertilizers' method in the 'UTInsolatorExpansion' class is updated to perform additional checks. Before assigning a value to 'fertilizers', it now verifies if the 'additionalFertilizers' list is not null and if the 'crafttweaker' mod is loaded. This addition enhances the robustness of the method by avoiding potential null pointer exceptions or issues related to the non-availability of the 'crafttweaker' mod.

@ACGaming ACGaming merged commit ba0bdfe into ACGaming:main Jul 30, 2024
1 check passed
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.

2 participants