winemenubuilder: In InvokeShellLinkerForURL, better replicate the deferral behavior in InvokeShellLinker.

This gives us a second chance, if the icon file doesn't exist yet
during the first call.
This commit is contained in:
Andrew Bogott 2010-12-11 11:58:04 -06:00 committed by Alexandre Julliard
parent 0eb6e40720
commit 4c386998b0
1 changed files with 13 additions and 0 deletions

View File

@ -2700,6 +2700,19 @@ static BOOL InvokeShellLinkerForURL( IUniformResourceLocatorW *url, LPCWSTR link
IPropertySetStorage_Release(pPropSetStg);
}
/* fail - try once again after parent process exit */
if( !icon_name )
{
if (bWait)
{
WINE_WARN("Unable to extract icon, deferring.\n");
ret = FALSE;
goto cleanup;
}
WINE_ERR("failed to extract icon from %s\n",
wine_dbgstr_w( pv[0].pwszVal ));
}
hSem = CreateSemaphoreA( NULL, 1, 1, "winemenubuilder_semaphore");
if( WAIT_OBJECT_0 != MsgWaitForMultipleObjects( 1, &hSem, FALSE, INFINITE, QS_ALLINPUT ) )
{