[ovs-dev] [InBandOVSDB 3/4] socket-util: Factor out new function inet_parse_active().

Ben Pfaff blp at nicira.com
Mon Apr 26 17:38:36 UTC 2010


On Mon, Apr 26, 2010 at 12:02:34AM -0700, Justin Pettit wrote:
> On Apr 20, 2010, at 4:37 PM, Ben Pfaff wrote:
> 
> > +/* Parses 'target', which should be a string in the format "<host>[:<port>]".
> > + * <host> is required.  If 'default_port' is nonzero then <port> is optional
> > + * and defaults to 'default_port'.
> >  *
> > + * On success, returns true and stores the parsed remote address into '*sinp'.
> > + * On failure, logs an error and returns false. */
> > +bool
> > +inet_parse_active(const char *target_, uint16_t default_port,
> > +                  struct sockaddr_in *sinp)
> 
> I believe the description should refer to "target_" instead of
> "target".  There are a few existing functions that have this same
> issue in the file.

That's a style I use.  You're supposed to pretend that the _ isn't
there.  (Seriously.)




More information about the dev mailing list