lordgamez commented on code in PR #1485:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1485#discussion_r1098469358


##########
libminifi/src/core/repository/VolatileContentRepository.cpp:
##########
@@ -86,7 +89,7 @@ std::shared_ptr<io::BaseStream> 
VolatileContentRepository::write(const minifi::R
     if (claim_check != master_list_.end()) {
       return 
std::make_shared<io::AtomicEntryStream<ResourceClaim::Path>>(claim.getContentFullPath(),
 claim_check->second);
     } else {
-      auto *ent = new AtomicEntry<ResourceClaim::Path>(&current_size_, 
&max_size_);
+      auto *ent = new 
AtomicEntry<ResourceClaim::Path>(&repo_data_.current_size, 
&repo_data_.max_size);

Review Comment:
   I'm not sure if it's a good idea as it is stored in the `master_list_` as a 
raw pointer where the ownership is not trivial. We have the `value_vector` of 
the repo data and the `master_list_` and the ownership between those 2 needs to 
be clarified first to see how the ownership should be handled.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to