phrocker commented on a change in pull request #529: MINIFICPP-792 - TailFile 
processor should handle rotation of source file
URL: https://github.com/apache/nifi-minifi-cpp/pull/529#discussion_r269994984
 
 

 ##########
 File path: libminifi/src/processors/PutFile.cpp
 ##########
 @@ -138,49 +138,18 @@ void PutFile::onTrigger(core::ProcessContext *context, 
core::ProcessSession *ses
     if (S_ISDIR(statResult.st_mode)) {
       // it's a directory, count the files
       int64_t ct = 0;
-#ifndef WIN32
-      DIR *myDir = opendir(directory.c_str());
-      if (!myDir) {
-        logger_->log_warn("Could not open %s", directory);
+      auto lambda = [&ct, this](const std::string&, const std::string&) -> 
bool {
 
 Review comment:
   If we're going to use lambdas here we need a comment here about what the 
return means for the follow on function. 

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