> On Jul 12, 2016, at 5:16 PM, Ben Pfaff <b...@ovn.org> wrote: > > On Mon, Jul 11, 2016 at 11:56:41PM -0700, Justin Pettit wrote: >> A future commit will reduce the amount of conversions used by the >> existing users of 'lport_addresses'. This change will also make it >> possible to use this structure for logical router port networks. >> >> Signed-off-by: Justin Pettit <jpet...@ovn.org> > > There's a lot of dynamic allocation here for strings that have a > specific length or a small bound. For example, 'ea_s' in struct > lport_addresses is always ETH_ADDR_STRLEN bytes long plus a null > terminator, but the code uses xasprintf(). Similarly, for IPv4 address > strings only INET_ADDRSTRLEN + 1 bytes, which is only 17 bytes, are > needed. I guess for most IPv6 addresses INET6_ADDRSTRLEN + 1 bytes, > which is 47, might be overkill.
Excellent point. Since I'm going to need to send out a non-RFC version of the IPv6 patches, I'll add that change to that series. I've got the changes queued up now. Thanks, --Justin _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev