On 10/21/20 12:32 PM, Stephen Hemminger wrote: > On Mon, 19 Oct 2020 17:23:01 +0200 > Guillaume Nault <gna...@redhat.com> wrote: > >> + } else if (matches(*argv, "pop_eth") == 0) { > > Using matches allows for shorter command lines but can be make > for bad user experience if strings overlap. > > For example 'p' here will match the pop_eth and not the push_eth. > > Is it time to use full string compare for these options? >
I thought the same, but let it go given the pervasive use of 'matches'. I do think iproute2 needs to stop adding more uses of it and forcing full strcmp's.