shell32: Remove dead code in SHELL_FindExecutable().

This commit is contained in:
Francois Gouget 2006-06-15 18:29:29 +02:00 committed by Alexandre Julliard
parent f248440dd4
commit 2d7ef72cf0
1 changed files with 3 additions and 32 deletions

View File

@ -607,38 +607,9 @@ UINT SHELL_FindExecutable(LPCWSTR lpPath, LPCWSTR lpFile, LPCWSTR lpOperation,
if (*filetype)
{
if (lpOperation)
{
/* pass the operation string to SHELL_FindExecutableByOperation() */
filetype[filetypelen] = '\0';
retval = SHELL_FindExecutableByOperation(lpPath, lpFile, lpOperation, key, filetype, command, sizeof(command));
}
else
{
WCHAR operation[MAX_PATH];
HKEY hkey;
/* Looking for ...buffer\shell\<operation>\command */
strcatW(filetype, wszShell);
/* enumerate the operation subkeys in the registry and search for one with an associated command */
if (RegOpenKeyW(HKEY_CLASSES_ROOT, filetype, &hkey) == ERROR_SUCCESS)
{
int idx = 0;
for(;; ++idx)
{
if (RegEnumKeyW(hkey, idx, operation, MAX_PATH) != ERROR_SUCCESS)
break;
filetype[filetypelen] = '\0';
retval = SHELL_FindExecutableByOperation(lpPath, lpFile, operation, key, filetype, command, sizeof(command));
if (retval > 32)
break;
}
RegCloseKey(hkey);
}
}
/* pass the operation string to SHELL_FindExecutableByOperation() */
filetype[filetypelen] = '\0';
retval = SHELL_FindExecutableByOperation(lpPath, lpFile, lpOperation, key, filetype, command, sizeof(command));
if (retval > 32)
{