diff --git a/reactos/dll/win32/shell32/shellord.cpp b/reactos/dll/win32/shell32/shellord.cpp index 77491c2e1af..13e17a15365 100644 --- a/reactos/dll/win32/shell32/shellord.cpp +++ b/reactos/dll/win32/shell32/shellord.cpp @@ -2269,7 +2269,9 @@ EXTERN_C HRESULT WINAPI SHGetImageList(int iImageList, REFIID riid, void **ppv) /* Get the interface for the new image list */ if (hNew) { - ret = HIMAGELIST_QueryInterface(hNew, riid, ppv); + IImageList *imageList = (IImageList*) hNew; + ret = imageList->QueryInterface(riid, ppv); + ImageList_Destroy(hNew); }