This repository was archived by the owner on Mar 8, 2020. It is now read-only.
Repository navigation
Fix leaks in HasPosition calls - #102
Merged
Merged
Conversation
dennwc
approved these changes
May 31, 2018
Member
|
This is exactly the reason why Go does not allow type conversion of ints to bool. |
Member
|
And please squash commits before merging. |
Contributor
Author
|
@dennwc not arguing that is a good feature to have, but the problem was not calling decref on the value returned by Attribute (the reason for the boolean wrapper is that I also dislike these type conversions). |
Signed-off-by: Juanjo Alvarez <[email protected]> Remove debug stuff Signed-off-by: Juanjo Alvarez <[email protected]>
juanjux
force-pushed
the
fix/positions_leak
branch
from
May 31, 2018 17:35
59563c1 to
1ca9bec
Compare
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #100.
Fix calls in the "HasXXX" position functions to
AttributeValuewithout decreasing the reference of the returned object or adding it to the memory tracker which were leaking in a specific caseAdded ugly warnings about the need to do that on
AttributeandAttributeValue.Added two new tests for memleaks covering the bug.
Updated the build to the latest libuast and changed URL.
Signed-off-by: Juanjo Alvarez [email protected]