bakaid commented on a change in pull request #563: WiP: MINIFICPP-839 - Fix 
memleaks
URL: https://github.com/apache/nifi-minifi-cpp/pull/563#discussion_r286041202
 
 

 ##########
 File path: libminifi/src/core/repository/VolatileContentRepository.cpp
 ##########
 @@ -81,10 +81,7 @@ void VolatileContentRepository::start() {
     return;
   if (running_)
     return;
-  thread_ = std::thread(&VolatileContentRepository::run, 
shared_from_parent<VolatileContentRepository>());
-  thread_.detach();
 
 Review comment:
   As far as I could gather it served no discernible purpose, but because a 
shared_ptr instance is capture in a detached thread it causes valgrind to issue 
a warning (as valgrind will evaluate memory leaks at exit()). 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to