mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-06 06:40:38 +00:00
ntdll: Use ARRAY_SIZE instead of open coding it.
This commit is contained in:
parent
e6069c2530
commit
f5c573b199
|
@ -635,7 +635,7 @@ static void init_paths( char *argv[] )
|
|||
static int pathname[] = { CTL_KERN, KERN_PROC, KERN_PROC_PATHNAME, -1 };
|
||||
size_t path_size = PATH_MAX;
|
||||
char *path = malloc( path_size );
|
||||
if (path && !sysctl( pathname, sizeof(pathname)/sizeof(pathname[0]), path, &path_size, NULL, 0 ))
|
||||
if (path && !sysctl( pathname, ARRAY_SIZE(pathname), path, &path_size, NULL, 0 ))
|
||||
bin_dir = realpath_dirname( path );
|
||||
free( path );
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue