If the registry key where the crash control settings are saved does not exist or opening this key fails for
some other reason, the releated dialog parts behave as they where not implemented (settings are not
saved, empty dump type list).
The attached patch does the following:
- In Load/WriteStartupRecoveryOptions, use RegCreateKeyEx instead of RegOpenKeyEx.
- Save the return value from RegCreateKeyEx to a variable. In case of an error, use SetLastError
to set the last error to this return value and call ShowLastWin32Error to inform the user about the
- If RegCreateKeyEx fails in LoadStartupRecoveryOptions, disable the related GUI elements and
don't try to safe the releated settings if the user hits ok.
- Also replace a LoadString with LoadStringW, since all other places use explicitly the unicode functions.