diff options
Diffstat (limited to 'gpg_wrapper.cpp')
-rw-r--r-- | gpg_wrapper.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/gpg_wrapper.cpp b/gpg_wrapper.cpp index 1a29440..fa8c8f7 100644 --- a/gpg_wrapper.cpp +++ b/gpg_wrapper.cpp @@ -21,8 +21,7 @@ pxResult pxExecute(wstring *acommandline, char *ainput, string *aoutput, LPDWORD aexitcode, pxResult *result) { - extern bool bDebugLog; - extern fstream debuglog; + extern logtofile debuglog; BOOL success; STARTUPINFO sinfo = {0}; SECURITY_ATTRIBUTES sattrs = {0}; @@ -87,12 +86,7 @@ pxResult pxExecute(wstring *acommandline, char *ainput, string *aoutput, LPDWORD mir_free(home_dir); } - if(bDebugLog) - { - char* tmp = mir_utf8encodeW(commandline.c_str()); - debuglog<<"in: "<<tmp<<"\n"; - mir_free(tmp); - } + debuglog<<"in: "<<commandline<<"\n"; TCHAR chNewEnv[128]; LPTSTR lpszCurrentVariable; @@ -132,10 +126,7 @@ pxResult pxExecute(wstring *acommandline, char *ainput, string *aoutput, LPDWORD storeOutput(readstdout,aoutput); - if(bDebugLog) - { - debuglog<<"out: "<<aoutput->c_str()<<"\n"; - } + debuglog<<"out: "<<aoutput->c_str()<<"\n"; WaitForSingleObject(pri.hProcess,INFINITE); |