diff options
Diffstat (limited to 'plugins/Db3x_mmap')
-rw-r--r-- | plugins/Db3x_mmap/dbcache.c | 2 | ||||
-rw-r--r-- | plugins/Db3x_mmap/dbcontacts.c | 2 | ||||
-rw-r--r-- | plugins/Db3x_mmap/dbevents.c | 12 | ||||
-rw-r--r-- | plugins/Db3x_mmap/dbsettings.c | 10 |
4 files changed, 13 insertions, 13 deletions
diff --git a/plugins/Db3x_mmap/dbcache.c b/plugins/Db3x_mmap/dbcache.c index 8e177c6f6d..625d8aa775 100644 --- a/plugins/Db3x_mmap/dbcache.c +++ b/plugins/Db3x_mmap/dbcache.c @@ -144,7 +144,7 @@ static VOID CALLBACK DoBufferFlushTimerProc(HWND hwnd, UINT message, UINT_PTR id void DBFlush(int setting)
{
- if(!setting) {
+ if (!setting) {
log0("nflush1");
if(safetyMode && pDbCache) {
if (FlushViewOfFile(pDbCache, 0) == 0) {
diff --git a/plugins/Db3x_mmap/dbcontacts.c b/plugins/Db3x_mmap/dbcontacts.c index 0803f1f746..51e533266d 100644 --- a/plugins/Db3x_mmap/dbcontacts.c +++ b/plugins/Db3x_mmap/dbcontacts.c @@ -153,7 +153,7 @@ static INT_PTR DeleteContact(WPARAM wParam,LPARAM lParam) struct DBEvent *dbe;
int index;
- if((HANDLE)wParam==NULL) return 1;
+ if ((HANDLE)wParam==NULL) return 1;
EnterCriticalSection(&csDbAccess);
dbc=(struct DBContact*)DBRead(wParam,sizeof(struct DBContact),NULL);
if(dbc->signature!=DBCONTACT_SIGNATURE) {
diff --git a/plugins/Db3x_mmap/dbevents.c b/plugins/Db3x_mmap/dbevents.c index 24c568f02d..5576455daf 100644 --- a/plugins/Db3x_mmap/dbevents.c +++ b/plugins/Db3x_mmap/dbevents.c @@ -135,7 +135,7 @@ static INT_PTR AddEvent(WPARAM wParam,LPARAM lParam) // Loop through the chain, starting at the end
ofsThis = dbc.ofsLastEvent;
dbeTest = (struct DBEvent*)DBRead(ofsThis, sizeof(struct DBEvent), NULL);
- for(;;) {
+ for (;;) {
// If the new event's timesstamp is equal to or greater than the
// current dbevent, it will be inserted after. If not, continue
// with the previous dbevent in chain.
@@ -159,7 +159,7 @@ static INT_PTR AddEvent(WPARAM wParam,LPARAM lParam) }
}
dbc.eventCount++;
- if(!(dbe.flags&(DBEF_READ|DBEF_SENT))) {
+ if (!(dbe.flags&(DBEF_READ|DBEF_SENT))) {
if(dbe.timestamp<dbc.timestampFirstUnread || dbc.timestampFirstUnread==0) {
dbc.timestampFirstUnread=dbe.timestamp;
dbc.ofsFirstUnreadEvent=ofsNew;
@@ -209,7 +209,7 @@ static INT_PTR DeleteEvent(WPARAM wParam,LPARAM lParam) //check if this was the first unread, if so, recalc the first unread
if(dbc.ofsFirstUnreadEvent==(DWORD)lParam) {
dbeNext=&dbe;
- for(;;) {
+ for (;;) {
if(dbeNext->ofsNext==0) {
dbc.ofsFirstUnreadEvent=0;
dbc.timestampFirstUnread=0;
@@ -217,7 +217,7 @@ static INT_PTR DeleteEvent(WPARAM wParam,LPARAM lParam) }
ofsThis=dbeNext->ofsNext;
dbeNext=(struct DBEvent*)DBRead(ofsThis,sizeof(struct DBEvent),NULL);
- if(!(dbeNext->flags&(DBEF_READ|DBEF_SENT))) {
+ if (!(dbeNext->flags&(DBEF_READ|DBEF_SENT))) {
dbc.ofsFirstUnreadEvent=ofsThis;
dbc.timestampFirstUnread=dbeNext->timestamp;
break;
@@ -340,7 +340,7 @@ static INT_PTR MarkEventRead(WPARAM wParam,LPARAM lParam) DBWrite(lParam,dbe,sizeof(struct DBEvent));
ret=(int)dbe->flags;
if(dbc.ofsFirstUnreadEvent==(DWORD)lParam) {
- for(;;) {
+ for (;;) {
if(dbe->ofsNext==0) {
dbc.ofsFirstUnreadEvent=0;
dbc.timestampFirstUnread=0;
@@ -348,7 +348,7 @@ static INT_PTR MarkEventRead(WPARAM wParam,LPARAM lParam) }
ofsThis=dbe->ofsNext;
dbe=(struct DBEvent*)DBRead(ofsThis,sizeof(struct DBEvent),NULL);
- if(!(dbe->flags&(DBEF_READ|DBEF_SENT))) {
+ if (!(dbe->flags&(DBEF_READ|DBEF_SENT))) {
dbc.ofsFirstUnreadEvent=ofsThis;
dbc.timestampFirstUnread=dbe->timestamp;
break;
diff --git a/plugins/Db3x_mmap/dbsettings.c b/plugins/Db3x_mmap/dbsettings.c index 85b91b1b6c..ab306e8b48 100644 --- a/plugins/Db3x_mmap/dbsettings.c +++ b/plugins/Db3x_mmap/dbsettings.c @@ -323,7 +323,7 @@ static __inline int GetContactSettingWorker(HANDLE hContact,DBCONTACTGETSETTING NeedBytes(3+*(PWORD)(pBlob+1));
if(isStatic) {
dbcgs->pValue->cchVal--;
- if(*(PWORD)(pBlob+1)<dbcgs->pValue->cchVal) dbcgs->pValue->cchVal=*(PWORD)(pBlob+1);
+ if (*(PWORD)(pBlob+1)<dbcgs->pValue->cchVal) dbcgs->pValue->cchVal=*(PWORD)(pBlob+1);
CopyMemory(dbcgs->pValue->pszVal,pBlob+3,dbcgs->pValue->cchVal);
dbcgs->pValue->pszVal[dbcgs->pValue->cchVal]=0;
dbcgs->pValue->cchVal=*(PWORD)(pBlob+1);
@@ -337,7 +337,7 @@ static __inline int GetContactSettingWorker(HANDLE hContact,DBCONTACTGETSETTING case DBVT_BLOB:
NeedBytes(3+*(PWORD)(pBlob+1));
if(isStatic) {
- if(*(PWORD)(pBlob+1)<dbcgs->pValue->cpbVal) dbcgs->pValue->cpbVal=*(PWORD)(pBlob+1);
+ if (*(PWORD)(pBlob+1)<dbcgs->pValue->cpbVal) dbcgs->pValue->cpbVal=*(PWORD)(pBlob+1);
CopyMemory(dbcgs->pValue->pbVal,pBlob+3,dbcgs->pValue->cpbVal);
}
else {
@@ -733,7 +733,7 @@ static INT_PTR WriteContactSetting(WPARAM wParam,LPARAM lParam) else bytesRequired=tmp.value.type;
bytesRequired+=2+settingNameLen;
bytesRequired+=ofsBlobPtr+1-(ofsSettingsGroup+offsetof(struct DBContactSettings,blob));
- if((DWORD)bytesRequired>dbcs.cbBlob) {
+ if ((DWORD)bytesRequired>dbcs.cbBlob) {
//doesn't fit: move entire group
struct DBContactSettings *dbcsPrev;
DWORD ofsDbcsPrev,ofsNew;
@@ -863,7 +863,7 @@ static INT_PTR DeleteContactSetting(WPARAM wParam,LPARAM lParam) MoveAlong(1+GetSettingValueLength(pBlob));
NeedBytes(1);
}
- if(!pBlob[0]) { //setting didn't exist
+ if (!pBlob[0]) { //setting didn't exist
LeaveCriticalSection(&csDbAccess);
return 1;
}
@@ -925,7 +925,7 @@ static INT_PTR EnumContactSettings(WPARAM wParam,LPARAM lParam) return -1;
}
dbces->ofsSettings=GetSettingsGroupOfsByModuleNameOfs(dbc,ofsModuleName);
- if(!dbces->ofsSettings) {
+ if (!dbces->ofsSettings) {
LeaveCriticalSection(&csDbAccess);
return -1;
}
|