From: Michael Stefaniuc mstefani@winehq.org
--- dlls/ntdll/unix/loader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/ntdll/unix/loader.c b/dlls/ntdll/unix/loader.c index c21d32ea811..0ed7a524db6 100644 --- a/dlls/ntdll/unix/loader.c +++ b/dlls/ntdll/unix/loader.c @@ -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 ); }
From: Michael Stefaniuc mstefani@winehq.org
--- dlls/riched20/tests/editor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/riched20/tests/editor.c b/dlls/riched20/tests/editor.c index 1661654aa11..9551f490a2d 100644 --- a/dlls/riched20/tests/editor.c +++ b/dlls/riched20/tests/editor.c @@ -9030,7 +9030,7 @@ static void test_window_classes(void) int i; HWND hwnd;
- for (i = 0; i < sizeof(test)/sizeof(test[0]); i++) + for (i = 0; i < ARRAY_SIZE(test); i++) { SetLastError(0xdeadbeef); hwnd = CreateWindowExA(0, test[i].class, NULL, WS_POPUP, 0, 0, 0, 0, 0, 0, 0, NULL);
From: Michael Stefaniuc mstefani@winehq.org
--- dlls/kernel32/tests/drive.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/dlls/kernel32/tests/drive.c b/dlls/kernel32/tests/drive.c index db9f626aaab..253638cd321 100644 --- a/dlls/kernel32/tests/drive.c +++ b/dlls/kernel32/tests/drive.c @@ -159,8 +159,7 @@ static void test_GetDiskFreeSpaceA(void) ret = GetDiskFreeSpaceA("C:\", §ors_per_cluster, &bytes_per_sector, &free_clusters, &total_clusters); ok(ret, "GetDiskFreeSpaceA error %ld\n", GetLastError());
- ret = GetVolumeNameForVolumeMountPointA("C:\", volume_guid_path, - sizeof(volume_guid_path) / sizeof(volume_guid_path[0])); + ret = GetVolumeNameForVolumeMountPointA("C:\", volume_guid_path, ARRAY_SIZE(volume_guid_path)); ok(ret, "GetVolumeNameForVolumeMountPointA error %ld\n", GetLastError());
ret = GetDiskFreeSpaceA(volume_guid_path, §ors_per_cluster, &bytes_per_sector, &free_clusters, &total_clusters); @@ -251,8 +250,7 @@ static void test_GetDiskFreeSpaceW(void) ret = GetDiskFreeSpaceW(c_drive_pathW, §ors_per_cluster, &bytes_per_sector, &free_clusters, &total_clusters); ok(ret, "GetDiskFreeSpaceW error %ld\n", GetLastError());
- ret = GetVolumeNameForVolumeMountPointW(c_drive_pathW, volume_guid_path, - sizeof(volume_guid_path) / sizeof(volume_guid_path[0])); + ret = GetVolumeNameForVolumeMountPointW(c_drive_pathW, volume_guid_path, ARRAY_SIZE(volume_guid_path)); ok(ret, "GetVolumeNameForVolumeMountPointW error %ld\n", GetLastError());
ret = GetDiskFreeSpaceW(volume_guid_path, §ors_per_cluster, &bytes_per_sector, &free_clusters, &total_clusters);
From: Michael Stefaniuc mstefani@winehq.org
--- server/unicode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/server/unicode.c b/server/unicode.c index 86a1217b01f..edb296be0c8 100644 --- a/server/unicode.c +++ b/server/unicode.c @@ -249,7 +249,7 @@ static char *get_nls_dir(void) dir = malloc( dir_size ); if (dir) { - if (sysctl( pathname, sizeof(pathname)/sizeof(pathname[0]), dir, &dir_size, NULL, 0 )) + if (sysctl( pathname, ARRAY_SIZE( pathname ), dir, &dir_size, NULL, 0 )) { free( dir ); dir = NULL;
From: Michael Stefaniuc mstefani@winehq.org
--- loader/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/loader/main.c b/loader/main.c index 242ff15accd..36e1f5f0967 100644 --- a/loader/main.c +++ b/loader/main.c @@ -90,7 +90,7 @@ static const char *get_self_exe( char *argv0 ) 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 )) return path; free( path ); #endif
From: Michael Stefaniuc mstefani@winehq.org
--- libs/wine/config.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libs/wine/config.c b/libs/wine/config.c index 23c76fda128..4eb446258cc 100644 --- a/libs/wine/config.c +++ b/libs/wine/config.c @@ -147,7 +147,7 @@ static char *get_runtime_exedir(void) static int pathname[] = { CTL_KERN, KERN_PROC, KERN_PROC_PATHNAME, -1 }; size_t dir_size = PATH_MAX; char *dir = malloc( dir_size ); - if (dir && !sysctl( pathname, sizeof(pathname)/sizeof(pathname[0]), dir, &dir_size, NULL, 0 )) + if (dir && !sysctl( pathname, ARRAY_SIZE( pathname ), dir, &dir_size, NULL, 0 )) return dir; free( dir ); return NULL;
Hi,
It looks like your patch introduced the new failures shown below. Please investigate and fix them before resubmitting your patch. If they are not new, fixing them anyway would help a lot. Otherwise please ask for the known failures list to be updated.
The tests also ran into some preexisting test failures. If you know how to fix them that would be helpful. See the TestBot job for the details:
The full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=125371
Your paranoid android.
=== debian11 (build log) ===
Task: Could not create the win32 wineprefix: Failed to disable the crash dialogs: Task: WineTest did not produce the win32 report
This merge request was approved by Huw Davies.