cmcfarlen commented on code in PR #9530:
URL: https://github.com/apache/trafficserver/pull/9530#discussion_r1140447466


##########
lib/swoc/src/swoc_ip.cc:
##########
@@ -1055,11 +1055,9 @@ IP6Range::load(std::string_view text) {
 
 IPRange::IPRange(IPAddr const &min, IPAddr const &max) {
   if (min.is_ip4() && max.is_ip4()) {
-    _range._ip4.assign(min.ip4(), max.ip4());
-    _family = AF_INET;
+    this->assign(min.ip4(), max.ip4());
   } else if (min.is_ip6() && max.is_ip6()) {
-    _range._ip6.assign(min.ip6(), max.ip6());
-    _family = AF_INET6;
+    this->assign(min.ip6(), max.ip6());
   }

Review Comment:
   I know this isn't part of these changes, but should there be some assert 
when the families are mismatched?



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