Thanks Ben for the review: Yes you are right, current patch is buggy as using same string twice with strtok_r() was always using first option instead of n options. Thanks for pointing out about svec.[ch]. I sent v2 https://patchwork.ozlabs.org/patch/1183774/ to address the same. PTAL.
Ali ________________________________ From: Ben Pfaff <[email protected]> Sent: Thursday, October 24, 2019 6:14 PM To: [email protected] <[email protected]> Cc: [email protected] <[email protected]>; Ginwala, Aliasgar <[email protected]> Subject: Re: [ovs-dev] [PATCH v1] command-line.c: Support parsing ctl options via env variable On Tue, Oct 15, 2019 at 06:52:34PM -0700, [email protected] wrote: > From: Aliasgar Ginwala <[email protected]> > > Signed-off-by: Aliasgar Ginwala <[email protected]> I'm pretty sure this code doesn't work properly because it tries to parse the same string twice with strtok_r(), which is going to truncate it after the first option. Did you try it with more than one space-separated option in the environment variable? lib/svec.[ch] would make it easier to write this. _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
