[PATCH v2 1/3] test: remove some strings from cmdline_etheraddr tests
Ferruh Yigit
ferruh.yigit at amd.com
Tue Oct 3 12:59:04 CEST 2023
On 10/3/2023 11:47 AM, Ferruh Yigit wrote:
> On 10/2/2023 7:37 PM, Stephen Hemminger wrote:
>> Some of the ethernet address formats which were invalid will
>> now become valid inputs when rte_ether_unformat_addr is modified
>> to allow leading zeros.
>>
>> Also, make local variables static.
>>
>> Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
>>
>
> <...>
>
>> @@ -61,10 +60,8 @@ const char * ether_addr_invalid_strs[] = {
>> "INVA:LIDC:HARS",
>> /* misc */
>> "01 23 45 67 89 AB",
>> - "01.23.45.67.89.AB",
>> "01,23,45,67,89,AB",
>> - "01:23:45\0:67:89:AB",
>> - "01:23:45#:67:89:AB",
>>
>
> Why these two are valid now?
>
> And I guess second one is still not valid, but first one is parsed as
> [1], is this expected?
>
> [1] 00:01:00:23:00:45
>
>
Ah, I guess it is taken as "XXXX:XXXX:XXXX" format, but number of digit
is not enforced, so "1:2:3" is a valid format, should we add this to API
documentation as example format? Or is this unintended side effect?
More information about the dev
mailing list