msharee9 commented on a change in pull request #775:
URL: https://github.com/apache/nifi-minifi-cpp/pull/775#discussion_r419743218



##########
File path: extensions/http-curl/client/HTTPClient.cpp
##########
@@ -296,12 +296,13 @@ bool HTTPClient::submit() {
   }
   curl_easy_setopt(http_session_, CURLOPT_HEADERFUNCTION, 
&utils::HTTPHeaderResponse::receive_headers);
   curl_easy_setopt(http_session_, CURLOPT_HEADERDATA, 
static_cast<void*>(&header_response_));
-  if (keep_alive_probe_ > 0){
-    logger_->log_debug("Setting keep alive to %d",keep_alive_probe_);
+  if (keep_alive_probe_.count() > 0) {
+    const auto keepAlive = 
std::chrono::duration_cast<std::chrono::duration<uint64_t>>(keep_alive_probe_);

Review comment:
       Agree that std::chrono::seconds is better here. However, on a side note, 
chrono::seconds is std::duration<int64_t>
   
https://gcc.gnu.org/onlinedocs/gcc-4.6.3/libstdc++/api/a00798_source.html#l00508
   
   It does not matter here if we use int64_t or uint64_t because we are 
checking for negative value.




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


Reply via email to