summaryrefslogtreecommitdiff
path: root/plugins/New_GPG
diff options
context:
space:
mode:
authorAlexander Gluzsky <sss123next@list.ru>2015-03-14 16:04:16 +0000
committerAlexander Gluzsky <sss123next@list.ru>2015-03-14 16:04:16 +0000
commita519adcb90671bb4e3958fba5997d4fad1d50a2f (patch)
treed7ea09d5bccf38b294c00292bcca6e7eb67ccfe1 /plugins/New_GPG
parent7358b315743f75d1f470dbe8dd80ee9fcbe27100 (diff)
new_gpg:
suppresed home dir variable attachment if it's empty (fix crashes on first run sanity check) git-svn-id: http://svn.miranda-ng.org/main/trunk@12399 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/New_GPG')
-rwxr-xr-xplugins/New_GPG/src/gpg_wrapper.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/plugins/New_GPG/src/gpg_wrapper.cpp b/plugins/New_GPG/src/gpg_wrapper.cpp
index 112d86080f..1f2e6090fe 100755
--- a/plugins/New_GPG/src/gpg_wrapper.cpp
+++ b/plugins/New_GPG/src/gpg_wrapper.cpp
@@ -47,9 +47,12 @@ pxResult pxExecute(std::vector<std::wstring> &aargv, string *aoutput, LPDWORD ae
env.push_back(L"LANGUAGE=en@quot");
env.push_back(L"LC_ALL=English");
argv.push_back(bin_path);
- argv.push_back(L"--homedir");
TCHAR *home_dir = UniGetContactSettingUtf(NULL, szGPGModuleName, "szHomePath", _T(""));
- argv.push_back(home_dir);
+ if(_tcslen(home_dir)) //this check are required for first run gpg binary validation
+ {
+ argv.push_back(L"--homedir");
+ argv.push_back(home_dir);
+ }
mir_free(home_dir);
argv.push_back(L"--display-charset");
argv.push_back(L"utf-8");