SHELL32: some fixes for shelllink's IContextMenu::InvokeCommand method

Martin Fuchs fuchs.martin at gmail.com
Thu Nov 3 00:45:04 CST 2005


Hello Mike,

On 03.11.2005 07:24:42 Mike McCormack wrote:
> ChangeLog:
> Pass the correct verb.
> Add a space between extra parameters.
> Wait for ShellExecute to complete.

[...]

>     if( ShellExecuteExW( &sei ) )
>+    {
>+        if (sei.hProcess)
>+            WaitForSingleObject(sei.hProcess, 10000);
>         r = S_OK;
>+    }
>     else
>         r = E_FAIL;

You should add an "CloseHandle(sei.hProcess);" after the wait call to
avoid the handle leak.

Regards,

    Martin



More information about the wine-devel mailing list