mirror of
https://github.com/systemd/systemd
synced 2024-07-21 02:05:05 +00:00
netif-naming: inline one iterator variable
This commit is contained in:
parent
07db7f6bb8
commit
acaa636866
|
@ -19,12 +19,10 @@ static const NamingScheme naming_schemes[] = {
|
|||
};
|
||||
|
||||
static const NamingScheme* naming_scheme_from_name(const char *name) {
|
||||
size_t i;
|
||||
|
||||
if (streq(name, "latest"))
|
||||
return naming_schemes + ELEMENTSOF(naming_schemes) - 1;
|
||||
|
||||
for (i = 0; i < ELEMENTSOF(naming_schemes); i++)
|
||||
for (size_t i = 0; i < ELEMENTSOF(naming_schemes); i++)
|
||||
if (streq(naming_schemes[i].name, name))
|
||||
return naming_schemes + i;
|
||||
|
||||
|
|
Loading…
Reference in a new issue