diff options
author | Rozhuk Ivan <rozhuk.im@gmail.com> | 2014-03-06 01:16:01 +0000 |
---|---|---|
committer | Rozhuk Ivan <rozhuk.im@gmail.com> | 2014-03-06 01:16:01 +0000 |
commit | 522586d7b8f7274fad2fe58c2615fc0d06618fcd (patch) | |
tree | 0a1e22eacb864e035af10f11021816d83163d974 /protocols/MRA/src/MraSendCommand.cpp | |
parent | d5adcdbd5c1fda81f1be805dadc8021837ed706d (diff) |
MRA
* Fix: SMS sending
SMS
* Fix: windows sizes then aero enabled
* Fix: ICQEVENTTYPE_SMSCONFIRMATION db event write
NewEventNotify
+ Add: support event types: ICQEVENTTYPE_SMS and ICQEVENTTYPE_SMSCONFIRMATION
git-svn-id: http://svn.miranda-ng.org/main/trunk@8423 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/MRA/src/MraSendCommand.cpp')
-rw-r--r-- | protocols/MRA/src/MraSendCommand.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/protocols/MRA/src/MraSendCommand.cpp b/protocols/MRA/src/MraSendCommand.cpp index 37341ba126..ed502a3cd9 100644 --- a/protocols/MRA/src/MraSendCommand.cpp +++ b/protocols/MRA/src/MraSendCommand.cpp @@ -443,14 +443,16 @@ DWORD CMraProto::MraSMSW(MCONTACT hContact, const CMStringA &lpszPhone, const CM {
CMStringA szPhoneLocal = "+" + CopyNumber(lpszPhone);
- OutBuffer buf, buf2;
+ OutBuffer buf;
buf.SetUL(0);
buf.SetLPS(szPhoneLocal);
buf.SetLPSW(lpwszMessage);
- buf2.SetLPS(szPhoneLocal);
- buf.SetLPSW(lpwszMessage);
- return MraSendQueueCMD(hSendQueueHandle, 0, hContact, ICQACKTYPE_SMS, buf2.Data(), buf2.Len(), MRIM_CS_SMS, buf.Data(), buf.Len());
+ LPBYTE lpbData = (LPBYTE)mir_calloc(lpszPhone.GetLength() + sizeof(size_t));
+ if (NULL == lpbData)
+ return (0);
+ memcpy(lpbData, lpszPhone, lpszPhone.GetLength());
+ return MraSendQueueCMD(hSendQueueHandle, 0, hContact, ICQACKTYPE_SMS, lpbData, lpszPhone.GetLength(), MRIM_CS_SMS, buf.Data(), buf.Len());
}
// Соединение с прокси
@@ -498,7 +500,7 @@ DWORD CMraProto::MraChangeUserBlogStatus(DWORD dwFlags, const CMStringW &wszText DWORD CMraProto::MraSendPacket(HANDLE m_hConnection, DWORD dwCMDNum, DWORD dwType, LPVOID lpData, size_t dwDataSize)
{
- LPBYTE lpbData = (LPBYTE)_alloca(dwDataSize+sizeof(mrim_packet_header_t));
+ LPBYTE lpbData = (LPBYTE)_alloca(dwDataSize + sizeof(mrim_packet_header_t));
mrim_packet_header_t *pmaHeader = (mrim_packet_header_t*)lpbData;
memset(pmaHeader, 0, sizeof(mrim_packet_header_t));
|