Module: wine Branch: master Commit: 5285756f938371457c3577ec9ad03ccacbcb658d URL: http://source.winehq.org/git/wine.git/?a=commit;h=5285756f938371457c3577ec9a...
Author: Dmitry Timoshkov dmitry@baikal.ru Date: Fri Nov 23 11:49:44 2012 +0800
windowscodecs: Add a NULL check to GetFrameCount of the PNG decoder.
---
dlls/windowscodecs/pngformat.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/dlls/windowscodecs/pngformat.c b/dlls/windowscodecs/pngformat.c index 4c94489..46a1908 100644 --- a/dlls/windowscodecs/pngformat.c +++ b/dlls/windowscodecs/pngformat.c @@ -640,6 +640,8 @@ static HRESULT WINAPI PngDecoder_GetThumbnail(IWICBitmapDecoder *iface, static HRESULT WINAPI PngDecoder_GetFrameCount(IWICBitmapDecoder *iface, UINT *pCount) { + if (!pCount) return E_INVALIDARG; + *pCount = 1; return S_OK; }