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: remove memory leak from reverse_binary_tree.cpp #2730

Merged

Conversation

vil02
Copy link
Member

@vil02 vil02 commented Sep 12, 2024

Description of Change

This PR adds a destructor to BinaryTree. Furthermore the copy constructor and the assignment operator was explicitly deleted in order to... simplify things.

Checklist

  • Added description of change
  • Added file name matches File name guidelines
  • Added tests and example, test must pass
  • Added documentation so that the program is self-explanatory and educational - Doxygen guidelines
  • Relevant documentation/comments is changed or added
  • PR title follows semantic commit guidelines
  • Search previous suggestions before making a new one, as yours may be a duplicate.
  • I acknowledge that all my contributions will be made under the project's license.

Notes:
Removes the memory leak from reverse_binary_tree.cpp.

@vil02 vil02 marked this pull request as ready for review September 12, 2024 18:10
@realstealthninja realstealthninja merged commit b169269 into TheAlgorithms:master Sep 13, 2024
7 checks passed
@vil02 vil02 deleted the memory_leak_reverse_binary_tree branch September 13, 2024 07:06
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.

2 participants