Module: wine Branch: master Commit: abfc151e0b1e0a8361514a71d8d288fbd5160673 URL: https://gitlab.winehq.org/wine/wine/-/commit/abfc151e0b1e0a8361514a71d8d288f...
Author: Alex Henrie alexhenrie24@gmail.com Date: Sun Jun 4 21:59:31 2023 -0600
mscms: Fix double free on error path in EnumColorProfilesA (scan-build).
If fileW is not null, it is freed at the end of the function.
---
dlls/mscms/profile.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/dlls/mscms/profile.c b/dlls/mscms/profile.c index 9c4b6be8342..5ecd5f83273 100644 --- a/dlls/mscms/profile.c +++ b/dlls/mscms/profile.c @@ -810,6 +810,7 @@ BOOL WINAPI EnumColorProfilesA( PCSTR machine, PENUMTYPEA record, PBYTE buffer, if (!(ret = header_from_file( fileW, &header ))) { free( fileW ); + fileW = NULL; continue; }