Skip to content

This should fix the interruption problem that channels have#41

Merged
cpw merged 2 commits intoMcModLauncher:mainfrom
cpw:uninterruptible
Jun 15, 2023
Merged

This should fix the interruption problem that channels have#41
cpw merged 2 commits intoMcModLauncher:mainfrom
cpw:uninterruptible

Conversation

@cpw
Copy link
Copy Markdown
Member

@cpw cpw commented Jun 12, 2023

Should close #37

cpw added 2 commits June 11, 2023 22:51
…by making our ZipFS File channels "uninterruptible".

Also, use Files.readAllBytes() to read stuff for InputStreams (how classloaders load stuff) as that makes it's internal streams uninterruptible too.

Signed-off-by: cpw <cpw+github@weeksfamily.ca>
…lose event. AbstractInterruptibleChannel seems to immediately close the underlying file channel so we should be able to detect.

Signed-off-by: cpw <cpw+github@weeksfamily.ca>
Copy link
Copy Markdown
Member

@marchermans marchermans left a comment

Choose a reason for hiding this comment

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

This looks good.
A bit hacky, but much better then setting the interrupt flag, since that can already be processed by the ZipFS systems earlier.

@cpw cpw merged commit 4e05cab into McModLauncher:main Jun 15, 2023
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.

Interrupts break class loading

2 participants