From 1f7cb06c22fb0fcd7228cbd1d210c0c2175548d0 Mon Sep 17 00:00:00 2001 From: Thomas Faber Date: Mon, 5 Mar 2018 18:51:24 +0100 Subject: [PATCH] [WINDOWSCODECS] Fix stack pointer corruption when handling PNGs. Without PNG_API_RULE defined, these functions (like all others) aren't stdcall. --- dll/win32/windowscodecs/typeof.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dll/win32/windowscodecs/typeof.h b/dll/win32/windowscodecs/typeof.h index 0d77ec9ab77..12e6b8bcc4e 100644 --- a/dll/win32/windowscodecs/typeof.h +++ b/dll/win32/windowscodecs/typeof.h @@ -76,8 +76,8 @@ typedef void (__cdecl typeof(png_write_info))(struct png_struct_def *, struct pn typedef void (__cdecl typeof(png_write_rows))(struct png_struct_def *, unsigned char **row, unsigned int); typedef unsigned int (__cdecl typeof(png_get_iCCP))(struct png_struct_def *, struct png_info_def *, char **, int *, char **, unsigned int *); typedef void (__cdecl typeof(png_set_crc_action))(struct png_struct_def *, int, int); -typedef void (__stdcall typeof(png_set_PLTE))(struct png_struct_def *, struct png_info_def *, const struct png_color_struct *, int); -typedef void (__stdcall typeof(png_set_tRNS))(struct png_struct_def *, struct png_info_def *, const unsigned char *, int, const struct png_color_16_struct *); +typedef void (__cdecl typeof(png_set_PLTE))(struct png_struct_def *, struct png_info_def *, const struct png_color_struct *, int); +typedef void (__cdecl typeof(png_set_tRNS))(struct png_struct_def *, struct png_info_def *, const unsigned char *, int, const struct png_color_16_struct *); typedef void (__cdecl typeof(png_set_filter))(struct png_struct_def *, int, int); typedef void *thandle_t_1; typedef int (*TIFFReadWriteProc_1)(thandle_t_1, void *, __typeof_intptr);