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

Possible memory leak in MD5Builder #7195

Closed
lrodorigo opened this issue Apr 6, 2020 · 1 comment · Fixed by #7197
Closed

Possible memory leak in MD5Builder #7195

lrodorigo opened this issue Apr 6, 2020 · 1 comment · Fixed by #7197

Comments

@lrodorigo
Copy link
Contributor

lrodorigo commented Apr 6, 2020

Hi all,
I noticed a possible memory leak in MD5 Builder addStream member function.

As you can see, if the readBytes fails, the function returns without freeing the allocated buffer.

@d-a-v d-a-v added this to the 2.7.0 milestone Apr 6, 2020
@earlephilhower
Copy link
Collaborator

@lrodorigo Looks like a potential leak to me! Want to do a PR for it and add the free before the return false?

lrodorigo pushed a commit to lrodorigo/Arduino-1 that referenced this issue Apr 7, 2020
@devyte devyte linked a pull request Apr 8, 2020 that will close this issue
@devyte devyte removed a link to a pull request Apr 8, 2020
@devyte devyte linked a pull request Apr 8, 2020 that will close this issue
earlephilhower added a commit that referenced this issue Apr 9, 2020
Co-authored-by: Luiss <luiss@mind.cc>
Co-authored-by: david gauchard <gauchard@laas.fr>
Co-authored-by: Develo <deveyes@gmail.com>
Co-authored-by: Earle F. Philhower, III <earlephilhower@yahoo.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants