Fix the memory leak caused by not releasing the memory of the PRNG at the end of the thread#1170
Merged
Merged
Fix the memory leak caused by not releasing the memory of the PRNG at the end of the thread#1170
Conversation
…s with test function ExistsKeypoints.
Contributor
|
Thank you for this fix. I think there is a way to avoid the compiler errors. Please have a look at: whuaegeanse#1. Let's see what the CI build does but we can safely drop support for older versions of GCC and other compilers at this point. Several years have passed since I originally wrote this code. |
…into colmap-user/jsch/prng-leak
Contributor
Author
|
@ahojnnes There seems to be no problem. But I have another question, does the extern variable PRNG need to be initialized to nullptr? There seems to be an implicit conversion and copy construction. Is there a certain overhead? |
Contributor
|
No, indeed, there is no need to initialize to the nullptr. We can drop it. Thanks. |
ahojnnes
enabled auto-merge (squash)
March 12, 2021 09:23
lucasthahn
pushed a commit
to tne-ai/colmap
that referenced
this pull request
Aug 17, 2022
… the end of the thread (colmap#1170) * Fix bugs of sift features matching. * Remove the return value. * Change names of function. And combine test function ExiststDescriptors with test function ExistsKeypoints. * Enhance the feature of testing keypoints and descriptors by using LRUCache. * Fix memory leak of PRNG * Add missing include file * Fix the problem of gcc compilation error * Try to fix the problem of gcc compilation error * Add missing operator * * Fix memory leak in thread local PRNG * Remove the meaningless copy construction code for PRNG Co-authored-by: Johannes Schönberger <joschonb@microsoft.com>
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
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.
Fix the memory leak caused by not releasing the memory of the PRNG at the end of the thread as mentioned by #1161.