X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/putty/blobdiff_plain/48f1bc4426f0c95919978b1eddd4744390355801..f3165540e742770b778e5276b124b0394158510d:/puttygen.c diff --git a/puttygen.c b/puttygen.c index e16b4f3d..8ce452a2 100644 --- a/puttygen.c +++ b/puttygen.c @@ -1107,6 +1107,8 @@ static int CALLBACK MainDlgProc(HWND hwnd, UINT msg, case IDC_SAVE: case IDC_EXPORT_OPENSSH: case IDC_EXPORT_SSHCOM: + if (HIWORD(wParam) != BN_CLICKED) + break; state = (struct MainDlgState *) GetWindowLong(hwnd, GWL_USERDATA); if (state->key_exists) { @@ -1200,6 +1202,8 @@ static int CALLBACK MainDlgProc(HWND hwnd, UINT msg, } break; case IDC_SAVEPUB: + if (HIWORD(wParam) != BN_CLICKED) + break; state = (struct MainDlgState *) GetWindowLong(hwnd, GWL_USERDATA); if (state->key_exists) { @@ -1233,6 +1237,8 @@ static int CALLBACK MainDlgProc(HWND hwnd, UINT msg, break; case IDC_LOAD: case IDC_IMPORT: + if (HIWORD(wParam) != BN_CLICKED) + break; state = (struct MainDlgState *) GetWindowLong(hwnd, GWL_USERDATA); if (!state->generation_thread_exists) {