Re: [ovs-dev] [PATCH] ovn-nbctl: Detect unrecognized short options in server mode.

2018-07-31 Thread Ben Pfaff
On Wed, Jul 25, 2018 at 05:26:54PM +0200, Jakub Sitnicki wrote: > Because getopt() will set optopt for both known and unknown options, > we need to differentiate between them ourselves by checking if we > know the option. Do that by looking up its value. > > Also, because we are using GNU

[ovs-dev] [PATCH] ovn-nbctl: Detect unrecognized short options in server mode.

2018-07-25 Thread Jakub Sitnicki
Because getopt() will set optopt for both known and unknown options, we need to differentiate between them ourselves by checking if we know the option. Do that by looking up its value. Also, because we are using GNU extensions to getopt(), we need to be resetting getopt() state by setting optind