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 ClassCastException and native crash when using kqueue transport. #8665

Merged
merged 1 commit into from Dec 19, 2018

Conversation

Projects
None yet
2 participants
@normanmaurer
Copy link
Member

normanmaurer commented Dec 16, 2018

Motivation:

How we did the mapping from native code to AbstractKQueueChannel was not safe and could lead to heap corruption. This then sometimes produced ClassCastExceptions or could also lead to crashes. This happened sometimes when running the testsuite.

Modifications:

Use a Map for the mapping (just as we do in the native epoll transport).

Result:

No more heap corruption / crashes.

Fix ClassCastException and native crash when using kqueue transport.
Motivation:

How we did the mapping from native code to AbstractKQueueChannel was not safe and could lead to heap corruption. This then sometimes produced ClassCastExceptions or could also lead to crashes. This happened sometimes when running the testsuite.

Modifications:

Use a Map for the mapping (just as we do in the native epoll transport).

Result:

No more heap corruption / crashes.
@normanmaurer

This comment has been minimized.

Copy link
Member Author

normanmaurer commented Dec 19, 2018

Let me also merge this so I can move forward. If we need we can do a followup.

@normanmaurer normanmaurer added this to the 4.1.33.Final milestone Dec 19, 2018

@normanmaurer normanmaurer added the defect label Dec 19, 2018

@normanmaurer normanmaurer merged commit d77bdea into 4.1 Dec 19, 2018

4 checks passed

pull request validation (centos6-java11) Build finished.
Details
pull request validation (centos6-java12) Build finished.
Details
pull request validation (centos6-java8) Build finished.
Details
pull request validation (centos6-java9) Build finished.
Details

@normanmaurer normanmaurer deleted the kqueue_native_cce branch Dec 19, 2018

normanmaurer added a commit that referenced this pull request Dec 19, 2018

Fix ClassCastException and native crash when using kqueue transport. (#…
…8665)

Motivation:

How we did the mapping from native code to AbstractKQueueChannel was not safe and could lead to heap corruption. This then sometimes produced ClassCastExceptions or could also lead to crashes. This happened sometimes when running the testsuite.

Modifications:

Use a Map for the mapping (just as we do in the native epoll transport).

Result:

No more heap corruption / crashes.
@carl-mastrangelo

This comment has been minimized.

Copy link
Member

carl-mastrangelo commented Dec 19, 2018

LGTM

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