szaszm commented on code in PR #1661:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1661#discussion_r1338500908


##########
libminifi/src/core/extension/ExtensionManager.cpp:
##########
@@ -31,9 +31,13 @@ namespace org::apache::nifi::minifi::core::extension {
 
 const std::shared_ptr<logging::Logger> ExtensionManager::logger_ = 
logging::LoggerFactory<ExtensionManager>::getLogger();
 
-ExtensionManager::ExtensionManager() {
-  modules_.push_back(std::make_unique<Executable>());
-  active_module_ = modules_[0].get();
+ExtensionManager::ExtensionManager()
+    : modules_([] {
+        std::vector<std::unique_ptr<Module>> modules;
+        modules.push_back(std::make_unique<Executable>());
+        return modules;
+      }()),

Review Comment:
   ```suggestion
       : modules_{std::make_unique<Executable>()},
   ```



##########
extensions/librdkafka/KafkaConnection.cpp:
##########
@@ -69,8 +70,8 @@ void KafkaConnection::setConnection(gsl::owner<rd_kafka_t*> 
producer) {
   startPoll();
 }
 
-rd_kafka_t *KafkaConnection::getConnection() const {
-  return kafka_connection_;
+rd_kafka_t* KafkaConnection::getConnection() const {
+  return static_cast<rd_kafka_t*>(kafka_connection_);

Review Comment:
   What made this explicit cast necessary, from `gsl::owner<rd_kafka_t*>` to 
`rd_kafka_t*`? `gsl::owner<T>` is a type alias to `T`.
   
    `gsl::owner<T>` is a type alias to `T`.



##########
libminifi/test/unit/FilePatternTests.cpp:
##########
@@ -8,7 +8,7 @@
  *
  *     http://www.apache.org/licenses/LICENSE-2.0
  *
- * Unless required by applicable law or agreed to in writing, software
+ * Unless CHECKd by applicable law or agreed to in writing, software

Review Comment:
   find and replace accident



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