diff options
author | George Hazan <ghazan@miranda.im> | 2018-03-15 15:34:59 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-03-15 15:34:59 +0300 |
commit | b572f4308e640ea46e9381ff642bed2950ffa888 (patch) | |
tree | e083208223c0be2138d88c055ef14659446af4a5 /plugins/UserInfoEx/src/ex_import/classExImContactXML.cpp | |
parent | 44b60862c97e5ec855d2bacd4d15f81f7ae7f410 (diff) |
warning fixes
Diffstat (limited to 'plugins/UserInfoEx/src/ex_import/classExImContactXML.cpp')
-rw-r--r-- | plugins/UserInfoEx/src/ex_import/classExImContactXML.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/plugins/UserInfoEx/src/ex_import/classExImContactXML.cpp b/plugins/UserInfoEx/src/ex_import/classExImContactXML.cpp index c6fa31e5ff..5c90624aaa 100644 --- a/plugins/UserInfoEx/src/ex_import/classExImContactXML.cpp +++ b/plugins/UserInfoEx/src/ex_import/classExImContactXML.cpp @@ -532,9 +532,6 @@ int CExImContactXML::LoadXmlElemnt(TiXmlElement *xContact) LPCSTR pUID = xContact->Attribute("uidv");
if (pUID != nullptr) {
- size_t valLen;
- PBYTE pbVal = nullptr;
-
switch (*(pUID++)) {
case 'b':
uid((BYTE)atoi(pUID));
@@ -553,9 +550,12 @@ int CExImContactXML::LoadXmlElemnt(TiXmlElement *xContact) uidu(pUID);
break;
case 'n':
- pbVal = (PBYTE)mir_base64_decode(pUID, &valLen);
- if (pbVal != nullptr)
- uidn(pbVal, valLen);
+ size_t valLen;
+ {
+ PBYTE pbVal = (PBYTE)mir_base64_decode(pUID, &valLen);
+ if (pbVal != nullptr)
+ uidn(pbVal, (DWORD)valLen);
+ }
break;
default:
uidu((LPCSTR)nullptr);
@@ -888,7 +888,7 @@ int CExImContactXML::ImportSetting(LPCSTR pszModule, TiXmlElement *xmlEntry) dbv.type = DBVT_BLOB;
dbv.pbVal = (PBYTE)mir_base64_decode(value + 1, &baselen);
if (dbv.pbVal != nullptr)
- dbv.cpbVal = baselen;
+ dbv.cpbVal = (WORD)baselen;
else {
mir_free(dbv.pbVal);
return ERROR_NOT_ADDED;
@@ -952,7 +952,7 @@ int CExImContactXML::ImportEvent(LPCSTR pszModule, TiXmlElement *xmlEvent) if (tmpVal != NULL) {
// event owning module
dbei.pBlob = tmpVal;
- dbei.cbBlob = baselen;
+ dbei.cbBlob = (WORD)baselen;
dbei.szModule = (LPSTR)pszModule;
xmlEvent->Attribute("type", (LPINT)&dbei.eventType);
|