[LOCALSPL]
authorColin Finck <colin@reactos.org>
Fri, 17 Jul 2015 13:00:49 +0000 (13:00 +0000)
committerColin Finck <colin@reactos.org>
Fri, 17 Jul 2015 13:00:49 +0000 (13:00 +0000)
Report any error that occured inside _OpenEnvironment.

svn path=/branches/colins-printing-for-freedom/; revision=68409

reactos/win32ss/printing/providers/localspl/printprocessors.c

index 5d6c178..d26175e 100644 (file)
@@ -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);