fgerlits commented on code in PR #1362:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1362#discussion_r924442120
##########
extensions/civetweb/processors/ListenHTTP.cpp:
##########
@@ -275,10 +277,10 @@ void
ListenHTTP::processRequestBuffer(core::ProcessSession *session) {
logger_->log_debug("ListenHTTP transferred %zu flow files from HTTP request
buffer", flow_file_count);
}
-ListenHTTP::Handler::Handler(std::string base_uri, core::ProcessContext
*context, std::string &&auth_dn_regex, std::string &&header_as_attrs_regex)
+ListenHTTP::Handler::Handler(std::string base_uri, core::ProcessContext
*context, std::string &&auth_dn_regex, std::optional<std::string>
&&headers_as_attrs_regex)
: base_uri_(std::move(base_uri)),
auth_dn_regex_(std::move(auth_dn_regex)),
- headers_as_attrs_regex_(std::move(header_as_attrs_regex)),
+ headers_as_attrs_regex_(std::move(headers_as_attrs_regex)),
process_context_(context) {
Review Comment:
The `move` at line 283 (now 284) is still not happening. I would change
this to
```c++
handler_ = std::make_unique<Handler>(basePath, context,
std::move(authDNPattern),
headersAsAttributesPattern.empty() ? std::nullopt :
std::make_optional<utils::Regex>(headersAsAttributesPattern));
```
and
```c++
ListenHTTP::Handler::Handler(std::string base_uri, core::ProcessContext
*context, std::string &&auth_dn_regex, std::optional<utils::Regex>
&&headers_as_attrs_regex)
: base_uri_(std::move(base_uri)),
auth_dn_regex_(std::move(auth_dn_regex)),
headers_as_attrs_regex_(std::move(headers_as_attrs_regex)),
process_context_(context) {
```
--
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]