summaryrefslogtreecommitdiff
path: root/options.cpp
diff options
context:
space:
mode:
authorGluzskiy Alexandr <sss@sss.chaoslab.ru>2011-10-19 08:39:19 +0300
committerGluzskiy Alexandr <sss@sss.chaoslab.ru>2011-10-19 08:39:19 +0300
commitb12986a6163f7634a20e34761b9b32776b64c226 (patch)
tree57632f4f5eb4b52222edab3e5f08e635b5c3b604 /options.cpp
parent3dad33945b29e49469d70d04b4ecc95a43c7b283 (diff)
modified: options.cpp
Diffstat (limited to 'options.cpp')
-rwxr-xr-xoptions.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/options.cpp b/options.cpp
index 8fcae69..b067cb3 100755
--- a/options.cpp
+++ b/options.cpp
@@ -359,9 +359,12 @@ static BOOL CALLBACK DlgProcGpgOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
{
char *szKey = UniGetContactSettingUtf(NULL, szGPGModuleName, "GPGPubKey", "");
EmptyClipboard();
- SetClipboardData(CF_OEMTEXT, szKey);
+ if(!SetClipboardData(CF_OEMTEXT, szKey))
+ {
+ mir_free(szKey);
+ MessageBoxA(0, "Error", "Failed to write to clipboard", MB_OK);
+ }
CloseClipboard();
- mir_free(szKey);
}
else
MessageBoxA(0, "Error", "Failed to open clipboard", MB_OK);