FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Fix Alloc-Dealloc mismatches by zawata · Pull Request #1943 · nodegit/nodegit · GitHub

Fix Alloc-Dealloc mismatches - #1943

Merged
zawata merged 3 commits into
nodegit:masterfrom
zawata:fix/alloc-dealloc-mismatch
Nov 26, 2025
Merged

Fix Alloc-Dealloc mismatches#1943
zawata merged 3 commits into
nodegit:masterfrom
zawata:fix/alloc-dealloc-mismatch

Conversation

zawata commented Oct 17, 2022
edited
Loading

Copy link
Copy Markdown
Contributor

An Alloc-Dealloc Mismatch causes undefined behavior. Kind of a minor problem but should be fixed nonetheless.

for more details
https://stackoverflow.com/a/10854437/4776273


if (!conversionResult.result) {
delete[] baton->{{ arg.name }};
// TODO free previously allocated memory

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Does this still need to be handled?

zawata Nov 3, 2022
edited
Loading

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

@julianmesa-gitkraken this comment came from you.

julianmesa-gitkraken Nov 7, 2022
edited
Loading

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Yes but I will do it in another PR. I need to store all allocated memory in a map, then if I get an error reading javascript arguments we have to release all allocated memory, then throw the error.

zawata force-pushed the fix/alloc-dealloc-mismatch branch from 42da6a6 to af08eb9 Compare November 7, 2022 17:55
zawata requested a review from ianhattendorf November 7, 2022 17:55
zawata force-pushed the fix/alloc-dealloc-mismatch branch from af08eb9 to 231f472 Compare November 26, 2025 19:14
zawata enabled auto-merge November 26, 2025 19:14
zawata merged commit 8cbf400 into nodegit:master Nov 26, 2025
17 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

3 participants


Back | FazBrowse Home | New Git URL