Revision: 7369
http://mahogany.svn.sourceforge.net/mahogany/?rev=7369&view=rev
Author: vadz
Date: 2007-09-08 03:53:36 -0700 (Sat, 08 Sep 2007)
Log Message:
-----------
fix data passing to GPG process in Unicode build
Modified Paths:
--------------
trunk/M/src/modules/crypt/PGPEngine.cpp
Modified: trunk/M/src/modules/crypt/PGPEngine.cpp
===================================================================
--- trunk/M/src/modules/crypt/PGPEngine.cpp 2007-09-08 00:19:52 UTC (rev
7368)
+++ trunk/M/src/modules/crypt/PGPEngine.cpp 2007-09-08 10:53:36 UTC (rev
7369)
@@ -252,10 +252,11 @@
pass;
messageOut.clear();
- wxChar buf[4096];
+ char bufOut[4096];
- size_t lenIn = messageIn.length();
- const wxChar *ptrIn = messageIn.c_str();
+ wxCharBuffer bufIn(messageIn.To8BitData());
+ size_t lenIn = strlen(bufIn);
+ const char *ptrIn = bufIn;
bool outEof = false,
errEof = false;
@@ -274,9 +275,9 @@
while ( out->CanRead() )
{
// leave space for terminating NUL
- buf[out->Read(buf, WXSIZEOF(buf) - 1).LastRead()] = '\0';
+ bufOut[out->Read(bufOut, WXSIZEOF(bufOut) - 1).LastRead()] = '\0';
- messageOut += buf;
+ messageOut += wxString::From8BitData(bufOut);
}
}
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Mahogany-cvsupdates mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates