Kaydet (Commit) a9056970 authored tarafından Enrico Tröger's avatar Enrico Tröger

Fix compiler warnings by correct type casting.

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2456 ea778897-0a13-0410-b9d1-a72fbfd435f5
üst 082cdec7
......@@ -8,6 +8,8 @@
* Makefile.am, scripts/intl_stats.sh, po/intl_stats.sh:
Move intl_stats.sh script back to po directory to not have to
include the scripts directory in the distribution.
* src/win32.c:
Fix compiler warnings by correct type casting.
2008-04-06 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
......
......@@ -1145,6 +1145,8 @@ static gboolean resolve_link(HWND hWnd, wchar_t *link, gchar **lpszPath)
HRESULT hres;
IShellLinkW *pslW = NULL;
IPersistFile *ppf = NULL;
LPVOID pslWV = NULL;
LPVOID ppfV = NULL;
/* Check if the file is empty first because IShellLink::Resolve for some reason succeeds
* with an empty file and returns an empty "link target". (#524151) */
......@@ -1160,18 +1162,20 @@ static gboolean resolve_link(HWND hWnd, wchar_t *link, gchar **lpszPath)
CoInitialize(NULL);
hres = CoCreateInstance(
&CLSID_ShellLink, NULL, CLSCTX_INPROC_SERVER, &IID_IShellLinkW, (LPVOID *) &pslW);
&CLSID_ShellLink, NULL, CLSCTX_INPROC_SERVER, &IID_IShellLinkW, &pslWV);
if (SUCCEEDED(hres))
{
/* The IShellLink interface supports the IPersistFile interface.
* Get an interface pointer to it. */
hres = pslW->lpVtbl->QueryInterface(pslW, &IID_IPersistFile, (LPVOID *) &ppf);
pslW = (IShellLinkW*) pslWV;
hres = pslW->lpVtbl->QueryInterface(pslW, &IID_IPersistFile, &ppfV);
}
if (SUCCEEDED(hres))
{
/* Load the file. */
ppf = (IPersistFile*) ppfV;
hres = ppf->lpVtbl->Load(ppf, link, STGM_READ);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment