forked from Mirrors/wine-wine
winebuild: Use the now available ARRAY_SIZE() macro.
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org> Signed-off-by: Alexandre Julliard <julliard@winehq.org>stable
parent
ec29d40e4e
commit
dd0e2616a7
|
@ -225,7 +225,7 @@ static void set_target( const char *target )
|
||||||
/* get the OS part */
|
/* get the OS part */
|
||||||
|
|
||||||
target_platform = PLATFORM_UNSPECIFIED; /* default value */
|
target_platform = PLATFORM_UNSPECIFIED; /* default value */
|
||||||
for (i = 0; i < sizeof(platform_names)/sizeof(platform_names[0]); i++)
|
for (i = 0; i < ARRAY_SIZE(platform_names); i++)
|
||||||
{
|
{
|
||||||
if (!strncmp( platform_names[i].name, platform, strlen(platform_names[i].name) ))
|
if (!strncmp( platform_names[i].name, platform, strlen(platform_names[i].name) ))
|
||||||
{
|
{
|
||||||
|
|
|
@ -943,7 +943,7 @@ int get_cpu_from_name( const char *name )
|
||||||
{
|
{
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
for (i = 0; i < sizeof(cpu_names)/sizeof(cpu_names[0]); i++)
|
for (i = 0; i < ARRAY_SIZE(cpu_names); i++)
|
||||||
if (!strcmp( cpu_names[i].name, name )) return cpu_names[i].cpu;
|
if (!strcmp( cpu_names[i].name, name )) return cpu_names[i].cpu;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue