mirror of
https://github.com/reactos/reactos.git
synced 2024-11-20 06:15:26 +00:00
[LOCALSPL]
Report any error that occured inside _OpenEnvironment. svn path=/branches/colins-printing-for-freedom/; revision=68409
This commit is contained in:
parent
a758d604df
commit
c8574e64e1
1 changed files with 9 additions and 0 deletions
|
@ -146,7 +146,10 @@ InitializePrintProcessorList()
|
|||
// Open the environment registry key.
|
||||
dwErrorCode = _OpenEnvironment(NULL, &hKey);
|
||||
if (dwErrorCode != ERROR_SUCCESS)
|
||||
{
|
||||
ERR("_OpenEnvironment failed with error %lu!\n", dwErrorCode);
|
||||
goto Cleanup;
|
||||
}
|
||||
|
||||
// Open the "Print Processors" subkey.
|
||||
dwErrorCode = (DWORD)RegOpenKeyExW(hKey, L"Print Processors", 0, KEY_READ, &hSubKey);
|
||||
|
@ -477,7 +480,10 @@ LocalEnumPrintProcessors(LPWSTR pName, LPWSTR pEnvironment, DWORD Level, LPBYTE
|
|||
// We use the registry and not the PrintProcessorList here, because the caller may request information about a different environment.
|
||||
dwErrorCode = _OpenEnvironment(pEnvironment, &hKey);
|
||||
if (dwErrorCode != ERROR_SUCCESS)
|
||||
{
|
||||
ERR("_OpenEnvironment failed with error %lu!\n", dwErrorCode);
|
||||
goto Cleanup;
|
||||
}
|
||||
|
||||
// Open the "Print Processors" subkey.
|
||||
dwErrorCode = (DWORD)RegOpenKeyExW(hKey, L"Print Processors", 0, KEY_READ, &hSubKey);
|
||||
|
@ -632,7 +638,10 @@ LocalGetPrintProcessorDirectory(LPWSTR pName, LPWSTR pEnvironment, DWORD Level,
|
|||
// Verify pEnvironment and open its registry key.
|
||||
dwErrorCode = _OpenEnvironment(pEnvironment, &hKey);
|
||||
if (dwErrorCode != ERROR_SUCCESS)
|
||||
{
|
||||
ERR("_OpenEnvironment failed with error %lu!\n", dwErrorCode);
|
||||
goto Cleanup;
|
||||
}
|
||||
|
||||
// Determine the size of the required buffer.
|
||||
dwErrorCode = (DWORD)RegQueryValueExW(hKey, L"Directory", NULL, NULL, NULL, pcbNeeded);
|
||||
|
|
Loading…
Reference in a new issue