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

Utf8FrameValidator must release buffer when validation fails #9909

Merged
merged 1 commit into from Dec 27, 2019

Conversation

@normanmaurer
Copy link
Member

normanmaurer commented Dec 27, 2019

Motivation:

Utf8FrameValidator must release the input buffer if the validation fails to ensure no memory leak happens

Modifications:

  • Catch exception, release frame and rethrow
  • Adjust unit test

Result:

Fixes #9906

Motivation:

Utf8FrameValidator must release the input buffer if the validation fails to ensure no memory leak happens

Modifications:

- Catch exception, release frame and rethrow
- Adjust unit test

Result:

Fixes #9906
@normanmaurer normanmaurer added this to the 4.1.45.Final milestone Dec 27, 2019
@normanmaurer

This comment has been minimized.

Copy link
Member Author

normanmaurer commented Dec 27, 2019

@kamma-cc PTAL

Copy link
Contributor

carryxyh left a comment

Looks good.

@carryxyh

This comment has been minimized.

Copy link
Contributor

carryxyh commented Dec 27, 2019

Another thing.. Seems like Utf8FrameValidator only have a empty doc..

/**
 *
 */
public class Utf8FrameValidator extends ChannelInboundHandlerAdapter

Looks confusing. Would u pls add some doc for this...

@kamma-cc

This comment has been minimized.

Copy link

kamma-cc commented Dec 27, 2019

@kamma-cc PTAL

Looks good.+1

@normanmaurer

This comment has been minimized.

Copy link
Member Author

normanmaurer commented Dec 27, 2019

@carryxyh will do in another pr

@normanmaurer normanmaurer merged commit 06a5173 into 4.1 Dec 27, 2019
3 checks passed
3 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
@normanmaurer normanmaurer deleted the validate_release branch Dec 27, 2019
normanmaurer added a commit that referenced this pull request Dec 27, 2019
Motivation:

Utf8FrameValidator must release the input buffer if the validation fails to ensure no memory leak happens

Modifications:

- Catch exception, release frame and rethrow
- Adjust unit test

Result:

Fixes #9906
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.