Dmitry Timoshkov : windowscodecs: Add a NULL check to GetFrameCount of the TGA decoder.
Module: wine Branch: master Commit: 03efd5c0f78354e1182133ec8246d09594ac38eb URL: http://source.winehq.org/git/wine.git/?a=commit;h=03efd5c0f78354e1182133ec82... Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Fri Nov 23 11:50:20 2012 +0800 windowscodecs: Add a NULL check to GetFrameCount of the TGA decoder. --- dlls/windowscodecs/tgaformat.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/dlls/windowscodecs/tgaformat.c b/dlls/windowscodecs/tgaformat.c index cd615c7..ac57e54 100644 --- a/dlls/windowscodecs/tgaformat.c +++ b/dlls/windowscodecs/tgaformat.c @@ -405,6 +405,8 @@ static HRESULT WINAPI TgaDecoder_GetThumbnail(IWICBitmapDecoder *iface, static HRESULT WINAPI TgaDecoder_GetFrameCount(IWICBitmapDecoder *iface, UINT *pCount) { + if (!pCount) return E_INVALIDARG; + *pCount = 1; return S_OK; }
participants (1)
-
Alexandre Julliard