You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@trafficserver.apache.org by GitBox <gi...@apache.org> on 2021/07/28 22:06:14 UTC

[GitHub] [trafficserver] ywkaras commented on a change in pull request #8181: Various maxmind_acl fixes

ywkaras commented on a change in pull request #8181:
URL: https://github.com/apache/trafficserver/pull/8181#discussion_r678684416



##########
File path: plugins/experimental/maxmind_acl/mmdb.cc
##########
@@ -406,6 +406,15 @@ Acl::eval(TSRemapRequestInfo *rri, TSHttpTxn txnp)
 {
   bool ret = default_allow;
   int mmdb_error;
+
+  auto sockaddr = TSHttpTxnClientAddrGet(txnp);
+
+  if (sockaddr == nullptr) {
+    TSDebug(PLUGIN_NAME, "Err during TsHttpClientAddrGet, nullptr returned");
+    ret = false;
+    return ret;
+  }
+

Review comment:
       I think you meant to change the next line to use sockaddr instead of calling TSHttpTxnClientAddrGet() again.




-- 
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: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org