X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8b1350d49d4366b1e1a59ff5bafadcf3336d00a7..dd9f8b6bb6935360a8271dc3e8749fb026b601a8:/src/msw/dde.cpp diff --git a/src/msw/dde.cpp b/src/msw/dde.cpp index 7604068ac6..550a8fc1cd 100644 --- a/src/msw/dde.cpp +++ b/src/msw/dde.cpp @@ -557,8 +557,8 @@ wxDDEConnection::DoExecute(const void *data, size_t size, wxIPCFormat format) _T("wxDDEServer::Execute() supports only text data") ); wxMemoryBuffer buffer; - LPBYTE realData wxDUMMY_INITIALIZE(NULL); - size_t realSize wxDUMMY_INITIALIZE(0); + LPBYTE realData = NULL; + size_t realSize = 0; wxMBConv *conv = NULL; // Windows only supports either ANSI or UTF-16 format depending on the @@ -636,16 +636,16 @@ wxDDEConnection::DoExecute(const void *data, size_t size, wxIPCFormat format) DWORD result; bool ok = DdeClientTransaction(realData, - realSize, - GetHConv(), - NULL, - // MSDN: if the transaction specified by - // the wType parameter does not pass data - // or is XTYP_EXECUTE, wFmt should be zero. - 0, - XTYP_EXECUTE, - DDE_TIMEOUT, - &result) != 0; + realSize*sizeof(wxChar), + GetHConv(), + NULL, + // MSDN: if the transaction specified by + // the wType parameter does not pass data + // or is XTYP_EXECUTE, wFmt should be zero. + 0, + XTYP_EXECUTE, + DDE_TIMEOUT, + &result) != 0; if ( !ok ) {