summaryrefslogtreecommitdiff
path: root/plugins/Db3x_mmap/dbsettings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Db3x_mmap/dbsettings.cpp')
-rw-r--r--plugins/Db3x_mmap/dbsettings.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/plugins/Db3x_mmap/dbsettings.cpp b/plugins/Db3x_mmap/dbsettings.cpp
index 451ea95501..90dfecd727 100644
--- a/plugins/Db3x_mmap/dbsettings.cpp
+++ b/plugins/Db3x_mmap/dbsettings.cpp
@@ -179,7 +179,7 @@ static DBVARIANT* GetCachedValuePtr( HANDLE hContact, char* szSetting, int bAllo
if ( bAllocate != 1 )
return NULL;
- V = HeapAlloc(hCacheHeap,HEAP_ZERO_MEMORY,sizeof(DBCachedContactValue));
+ V = (DBCachedContactValue *)HeapAlloc(hCacheHeap, HEAP_ZERO_MEMORY, sizeof(DBCachedContactValue));
if (VL->last)
VL->last->next = V;
else
@@ -341,7 +341,7 @@ static __inline int GetContactSettingWorker(HANDLE hContact,DBCONTACTGETSETTING
CopyMemory(dbcgs->pValue->pbVal,pBlob+3,dbcgs->pValue->cpbVal);
}
else {
- dbcgs->pValue->pbVal=(char*)mir_alloc(*(PWORD)(pBlob+1));
+ dbcgs->pValue->pbVal=(BYTE *)mir_alloc(*(PWORD)(pBlob+1));
CopyMemory(dbcgs->pValue->pbVal,pBlob+3,*(PWORD)(pBlob+1));
}
dbcgs->pValue->cpbVal=*(PWORD)(pBlob+1);
@@ -402,7 +402,7 @@ static INT_PTR GetContactSetting(WPARAM wParam,LPARAM lParam)
}
else {
dgs->pValue->type = DBVT_ASCIIZ;
- dgs->pValue->pszVal = mir_alloc( result );
+ dgs->pValue->pszVal = (char *)mir_alloc(result);
WideCharToMultiByte( mirCp, WC_NO_BEST_FIT_CHARS, tmp, -1, dgs->pValue->pszVal, result, NULL, NULL );
mir_free( tmp );
}
@@ -515,7 +515,7 @@ static INT_PTR SetSettingResident(WPARAM wParam,LPARAM lParam)
if ( !li.List_GetIndex( &lSettings, szTemp, &idx ))
szSetting = InsertCachedSetting( szTemp, cbSettingNameLen, idx );
else
- szSetting = lSettings.items[ idx ];
+ szSetting = (char *)lSettings.items[idx];
*szSetting = (char)wParam;
@@ -955,7 +955,7 @@ static INT_PTR EnumResidentSettings(WPARAM wParam,LPARAM lParam)
int i;
int ret;
for(i = 0; i < lResidentSettings.realCount; i++) {
- ret=((DBMODULEENUMPROC)lParam)(lResidentSettings.items[i],0,wParam);
+ ret=((DBMODULEENUMPROC)lParam)((char *)lResidentSettings.items[i], 0, wParam);
if(ret) return ret;
}
return 0;
@@ -989,17 +989,17 @@ int InitSettings(void)
hSettingChangeEvent=CreateHookableEvent(ME_DB_CONTACT_SETTINGCHANGED);
- hCacheHeap=HeapCreate(0,0,0);
- lSettings.sortFunc=stringCompare;
- lSettings.increment=100;
- lContacts.sortFunc=HandleKeySort;
- lContacts.increment=50;
- lGlobalSettings.sortFunc=HandleKeySort;
- lGlobalSettings.increment=50;
- lResidentSettings.sortFunc=stringCompare2;
- lResidentSettings.increment=50;
-
- mirCp = CallService( MS_LANGPACK_GETCODEPAGE, 0, 0 );
+ hCacheHeap = HeapCreate(0, 0, 0);
+ lSettings.sortFunc = (FSortFunc)stringCompare;
+ lSettings.increment = 100;
+ lContacts.sortFunc = HandleKeySort;
+ lContacts.increment = 50;
+ lGlobalSettings.sortFunc = HandleKeySort;
+ lGlobalSettings.increment = 50;
+ lResidentSettings.sortFunc = (FSortFunc)stringCompare2;
+ lResidentSettings.increment = 50;
+
+ mirCp = CallService(MS_LANGPACK_GETCODEPAGE, 0, 0);
return 0;
}