Mercurial > trustbridge
changeset 185:ee37c085b9f7
Try to handle crypt32 errors. Print the error code as fallback
author | Andre Heinecke <aheinecke@intevation.de> |
---|---|
date | Tue, 25 Mar 2014 18:03:49 +0000 |
parents | 1f44aae4528e |
children | 2551ad24d3c2 a3bde2aaabd9 |
files | cinst/windowsstore.c |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/cinst/windowsstore.c Tue Mar 25 18:03:00 2014 +0000 +++ b/cinst/windowsstore.c Tue Mar 25 18:03:49 2014 +0000 @@ -17,7 +17,7 @@ NULL, err, 0, (LPWSTR) &bufPtr, 0, NULL); if (!bufPtr) { - HMODULE hWinhttp = GetModuleHandleW (L"winhttp"); + HMODULE hWinhttp = GetModuleHandleW (L"crypt32"); if (hWinhttp) { FormatMessageW (FORMAT_MESSAGE_ALLOCATE_BUFFER | @@ -28,7 +28,7 @@ } } if (!bufPtr) - printf ("Error getting last error\n"); + printf ("Error getting last error for code: %lx \n", err); return bufPtr; }