diff options
author | George Hazan <george.hazan@gmail.com> | 2014-11-28 22:03:37 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2014-11-28 22:03:37 +0000 |
commit | d9bcb8029e8ac6b1ddee53908419d47d08a0d6a7 (patch) | |
tree | f15bb5782c6861a8a6a96644b6ab1d51a6aa1628 /protocols/MRA/src/Mra_functions.cpp | |
parent | 0392fb947b5b95e4595ab9508d01a795a2b0e057 (diff) |
- compilation fix;
- code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@11140 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/MRA/src/Mra_functions.cpp')
-rw-r--r-- | protocols/MRA/src/Mra_functions.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/protocols/MRA/src/Mra_functions.cpp b/protocols/MRA/src/Mra_functions.cpp index 9a44569713..3893bab587 100644 --- a/protocols/MRA/src/Mra_functions.cpp +++ b/protocols/MRA/src/Mra_functions.cpp @@ -184,10 +184,10 @@ void MraAddrListFree(MRA_ADDR_LIST *pmalAddrList) bool DB_GetStaticStringA(MCONTACT hContact, LPCSTR lpszModule, LPCSTR lpszValueName, LPSTR lpszRetBuff, size_t dwRetBuffSize, size_t *pdwRetBuffSize)
{
bool bRet = false;
- size_t dwReadedStringLen, dwRetBuffSizeLocal;
+
DBVARIANT dbv = { 0 };
if (db_get_ws(hContact, lpszModule, lpszValueName, &dbv) == 0) {
- dwReadedStringLen = lstrlenW(dbv.pwszVal);
+ int dwRetBuffSizeLocal, dwReadedStringLen = lstrlenW(dbv.pwszVal);
if (lpszRetBuff && (dwRetBuffSize > dwReadedStringLen)) {
dwRetBuffSizeLocal = WideCharToMultiByte(MRA_CODE_PAGE, 0, dbv.pwszVal, dwReadedStringLen, lpszRetBuff, dwRetBuffSize, NULL, NULL);
(*((CHAR*)(lpszRetBuff + dwRetBuffSizeLocal))) = 0;
|