JosiahWI commented on code in PR #9951:
URL: https://github.com/apache/trafficserver/pull/9951#discussion_r1253497520


##########
iocore/net/YamlSNIConfig.cc:
##########
@@ -213,6 +213,38 @@ std::set<std::string> valid_sni_config_keys = {TS_fqdn,
 namespace YAML
 {
 template <> struct convert<YamlSNIConfig::Item> {
+  static ts::port_range_t
+  parse_single_inbound_port_range(Node const &node, swoc::TextView port_view)
+  {
+    auto min{port_view.split_prefix_at('-')};
+    if (!min) {
+      min = port_view;
+    }
+    auto const &max{port_view};
+
+    swoc::TextView parsed_min;
+    long min_port{swoc::svtoi(min, &parsed_min)};
+    swoc::TextView parsed_max;
+    long max_port{swoc::svtoi(max, &parsed_max)};

Review Comment:
   I suppose the focus is on using `auto`, but what's the reason for using copy 
initialization over universal initialization in this case?



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