[ovs-dev] [PATCH 21/23] packets: New function ip_parse_masked().

Ben Pfaff blp at nicira.com
Fri Oct 16 20:54:40 UTC 2015


On Thu, Oct 15, 2015 at 06:31:51PM -0700, Justin Pettit wrote:
> 
> > On Oct 9, 2015, at 9:21 PM, Ben Pfaff <blp at nicira.com> wrote:
> > 
> > Signed-off-by: Ben Pfaff <blp at nicira.com>
> > 
> > +char * OVS_WARN_UNUSED_RESULT
> > +ip_parse_masked(const char *s, ovs_be32 *ip, ovs_be32 *mask)
> 
> It might be nice to provide a comment describing this function.

OK, done:

/* Parses string 's', which must be an IP address with an optional netmask or
 * CIDR prefix length.  Stores the IP address into '*ip' and the netmask into
 * '*mask'.  (If 's' does not contain a netmask, 255.255.255.255 is
 * assumed.)
 *
 * Returns NULL if successful, otherwise an error message that the caller must
 * free(). */

> Acked-by: Justin Pettit <jpettit at nicira.com>

Thanks!



More information about the dev mailing list