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: release opaque data on error in produce #954

Merged
merged 1 commit into from
May 22, 2022

Conversation

emelski
Copy link
Contributor

@emelski emelski commented May 4, 2022

When there is an error trying to produce() messages,
no delivery report is ever generated for the message.
If the user specified opaque data for the message,
the call to produce() will have "pinned" it, but with
no delivery report, it is never released. This change
checks for this condition and releases the opaque
data when this happens.

Fixes: #953

When there is an error trying to produce() messages,
no delivery report is ever generated for the message.
If the user specified `opaque` data for the message,
the call to produce() will has "pinned" it, but with
no delivery report, it is never released.  This change
checks for this condition and releases the opaque
data when this happens.

Fixes: Blizzard#953
@iradul
Copy link
Collaborator

iradul commented May 22, 2022

Thank you for the PR!

@iradul iradul merged commit 5de5935 into Blizzard:master May 22, 2022
henrinormak pushed a commit to 6fold/node-rdkafka that referenced this pull request Aug 23, 2022
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.

memory leak on exception in produce() when using opaque data
2 participants