mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 08:43:19 -04:00
Call strlen() once instead of twice.
This commit is contained in:
parent
b4edbce08c
commit
56700d4634
1 changed files with 2 additions and 2 deletions
|
|
@ -374,9 +374,9 @@ dev_stdclone(char *name, char **namep, char *stem, int *unit)
|
|||
{
|
||||
int u, i;
|
||||
|
||||
if (bcmp(stem, name, strlen(stem)) != 0)
|
||||
return (0);
|
||||
i = strlen(stem);
|
||||
if (bcmp(stem, name, i) != 0)
|
||||
return (0);
|
||||
if (!isdigit(name[i]))
|
||||
return (0);
|
||||
u = 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue