Don't touch the This pointer after it has been freed.
This commit is contained in:
parent
0c32905ccc
commit
1a7a947314
|
@ -122,8 +122,9 @@ static ULONG WINAPI IDropTargetHelper_fnRelease (IDropTargetHelper * iface)
|
|||
TRACE ("(%p)->(count=%lu)\n", This, This->ref);
|
||||
|
||||
if (!--(This->ref)) {
|
||||
TRACE ("-- destroying (%p)\n", This);
|
||||
LocalFree ((HLOCAL) This);
|
||||
TRACE("-- destroying (%p)\n", This);
|
||||
LocalFree ((HLOCAL) This);
|
||||
return 0;
|
||||
}
|
||||
return This->ref;
|
||||
}
|
||||
|
|
|
@ -172,6 +172,7 @@ static ULONG WINAPI ISF_Desktop_fnRelease (IShellFolder2 * iface)
|
|||
if (This->sPathTarget)
|
||||
SHFree (This->sPathTarget);
|
||||
LocalFree ((HLOCAL) This);
|
||||
return 0;
|
||||
}
|
||||
return This->ref;
|
||||
}
|
||||
|
|
|
@ -173,10 +173,11 @@ static ULONG WINAPI ISF_MyComputer_fnRelease (IShellFolder2 * iface)
|
|||
TRACE ("(%p)->(count=%lu)\n", This, This->ref);
|
||||
|
||||
if (!--(This->ref)) {
|
||||
TRACE ("-- destroying IShellFolder(%p)\n", This);
|
||||
if (This->pidlRoot)
|
||||
SHFree (This->pidlRoot);
|
||||
LocalFree ((HLOCAL) This);
|
||||
TRACE ("-- destroying IShellFolder(%p)\n", This);
|
||||
if (This->pidlRoot)
|
||||
SHFree (This->pidlRoot);
|
||||
LocalFree ((HLOCAL) This);
|
||||
return 0;
|
||||
}
|
||||
return This->ref;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue