From a3edb733a773ea37c1754eed8ee769be40a6c926 Mon Sep 17 00:00:00 2001 From: Tony Wasserka Date: Fri, 21 Aug 2009 11:12:03 +0200 Subject: [PATCH] windowscodecs: Support Stat for memory streams in IWICStream. --- dlls/windowscodecs/stream.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/dlls/windowscodecs/stream.c b/dlls/windowscodecs/stream.c index ebf64cbd104..ba1b2a6498a 100644 --- a/dlls/windowscodecs/stream.c +++ b/dlls/windowscodecs/stream.c @@ -194,8 +194,16 @@ static HRESULT WINAPI StreamOnMemory_UnlockRegion(IStream *iface, static HRESULT WINAPI StreamOnMemory_Stat(IStream *iface, STATSTG *pstatstg, DWORD grfStatFlag) { - FIXME("(%p): stub\n", iface); - return E_NOTIMPL; + StreamOnMemory *This = (StreamOnMemory*)iface; + TRACE("(%p)\n", This); + + if (!pstatstg) return E_INVALIDARG; + + ZeroMemory(pstatstg, sizeof(STATSTG)); + pstatstg->type = STGTY_STREAM; + pstatstg->cbSize.QuadPart = This->dwMemsize; + + return S_OK; } /* Clone isn't implemented in the native windowscodecs DLL either */ -- 2.11.4.GIT