On Monday 2020-10-12 19:04, Stephen Hemminger wrote:
>
>> +static struct color_code {
>> + const char match[8], *code;
>> + int len;
>> +} color_codes[C_MAX] = {
>> + {"iface="}, {"lladdr="}, {"v4addr="}, {"v6addr="}, {"operup="},
>> + {"operdn="}, {"clear=", "0", 1},
>> };
>
>Also if each match has = that maybe redundant.The = is needed so that strncmp in set_color_palette will do an equality match on the key name rather than a prefix match.
