summaryrefslogtreecommitdiff
path: root/main.cpp
diff options
context:
space:
mode:
authorGluzskiy Alexandr <sss123next@list.ru>2010-08-16 03:49:17 +0300
committerGluzskiy Alexandr <sss123next@list.ru>2010-08-16 03:49:17 +0300
commit4b450ea4b601cdb2fe0a2ee42170a6b552738a52 (patch)
tree13a38638a1bcbd43b4e733e5d9a71ff909c7ff4a /main.cpp
parent6e0a54a479bbcb862df2f69945aa5e3d16ad9db2 (diff)
modified: main.cpp
modified: new_gpg.rc modified: options.cpp
Diffstat (limited to 'main.cpp')
-rw-r--r--main.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/main.cpp b/main.cpp
index a339d6d..5c98c2c 100644
--- a/main.cpp
+++ b/main.cpp
@@ -355,7 +355,9 @@ static BOOL CALLBACK DlgProcKeyGenDialog(HWND hwndDlg, UINT msg, WPARAM wParam,
{
TranslateDialogDefault(hwndDlg);
ComboBoxAddStringUtf(GetDlgItem(hwndDlg, IDC_KEY_TYPE), _T("RSA"), 0);
- ComboBoxAddStringUtf(GetDlgItem(hwndDlg, IDC_KEY_TYPE), _T("DSA"), 0);
+ ComboBoxAddStringUtf(GetDlgItem(hwndDlg, IDC_KEY_TYPE), _T("DSA"), 1);
+ SetDlgItemInt(hwndDlg, IDC_KEY_EXPIRE_DATE, 0, 0);
+ SetDlgItemInt(hwndDlg, IDC_KEY_LENGTH, 2048, 0);
return TRUE;
}
@@ -655,7 +657,7 @@ static BOOL CALLBACK DlgProcLoadExistingKey(HWND hwndDlg,UINT msg,WPARAM wParam,
DWORD code;
string::size_type p = 0, p2 = 0, stop = 0;
{
- wstring cmd = _T("--list-secret-keys");
+ wstring cmd = _T("--list-keys");
if(pxExecute(&cmd, "", &out, &code) == pxNotFound)
{
MessageBox(0, _T("Set path to gpg.exe first!"), _T("Warning"), MB_OK);
@@ -665,7 +667,7 @@ static BOOL CALLBACK DlgProcLoadExistingKey(HWND hwndDlg,UINT msg,WPARAM wParam,
cp866_to_cp1251(&out);
while(p != string::npos)
{
- if((p = out.find("sec ", p)) == string::npos)
+ if((p = out.find("pub ", p)) == string::npos)
break;
p += 5;
if(p < stop)
@@ -693,7 +695,7 @@ static BOOL CALLBACK DlgProcLoadExistingKey(HWND hwndDlg,UINT msg,WPARAM wParam,
tmp = mir_a2t(out.substr(p,p2-p).c_str());
ListView_SetItemText(hwndList, iRow, 1, tmp);
mir_free(tmp);
- p = out.find("ssb ", p2) + 6;
+ p = out.find("sub ", p2) + 6;
p = out.find(" ", p) + 1;
p2 = out.find("\n", p);
tmp = mir_a2t(out.substr(p,p2-p-1).c_str());