summaryrefslogtreecommitdiff
path: root/plugins/Dbx_mdb/src/dbintf.h
diff options
context:
space:
mode:
authorMikalaiR <nikolay.romanovich@narod.ru>2016-03-02 15:41:48 +0000
committerMikalaiR <nikolay.romanovich@narod.ru>2016-03-02 15:41:48 +0000
commit336401d1771d74771246ac7e3ec6e3b1e562a98e (patch)
tree1d6d0df96dec368e9af0b6feabd1637877e1cef4 /plugins/Dbx_mdb/src/dbintf.h
parent3ec4883a6f1dc06a030cd8e64ab6f519982ed1ce (diff)
dbx_lmdb: code cleanup
git-svn-id: http://svn.miranda-ng.org/main/trunk@16392 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Dbx_mdb/src/dbintf.h')
-rw-r--r--plugins/Dbx_mdb/src/dbintf.h53
1 files changed, 4 insertions, 49 deletions
diff --git a/plugins/Dbx_mdb/src/dbintf.h b/plugins/Dbx_mdb/src/dbintf.h
index f744b37d96..706b9e648b 100644
--- a/plugins/Dbx_mdb/src/dbintf.h
+++ b/plugins/Dbx_mdb/src/dbintf.h
@@ -25,26 +25,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include <m_db_int.h>
-/* tree diagram
-
-DBHeader
-|-->end of file (plain offset)
-|-->first contact (DBContact)
-| |-->next contact (DBContact)
-| | \--> ...
-| |-->first settings (DBContactSettings)
-| | |-->next settings (DBContactSettings)
-| | | \--> ...
-| | \-->module name (DBModuleName)
-| \-->first/last/firstunread event
-|-->user contact (DBContact)
-| |-->next contact = NULL
-| |-->first settings as above
-| \-->first/last/firstunread event as above
-\-->first module name (DBModuleName)
-\-->next module name (DBModuleName)
-\--> ...
-*/
+#pragma warning (disable: 4200)
#define DBMODE_SHARED 0x0001
#define DBMODE_READONLY 0x0002
@@ -83,7 +64,7 @@ struct DBModuleName
{
DWORD dwSignature;
BYTE cbName; // number of characters in this module name
- char name[1]; // name, no nul terminator
+ char name[]; // name, no nul terminator
};
#define DBEVENT_SIGNATURE 0x45DECADEu
@@ -214,13 +195,6 @@ protected:
bool Remap();
bool Map();
-public: // Check functions
- int WorkInitialChecks(int);
- int WorkModuleChain(int);
- int WorkUser(int);
- int WorkContactChain(int);
- int WorkAggressive(int);
- int WorkFinalTasks(int);
protected:
TCHAR* m_tszProfileName;
@@ -259,7 +233,7 @@ protected:
MDB_dbi m_dbContacts;
MDB_cursor *m_curContacts;
- DWORD m_contactCount, m_dwMaxContactId;
+ DWORD m_contactCount, m_dwMaxContactId;
void GatherContactHistory(MCONTACT hContact, LIST<EventItem> &items);
@@ -293,30 +267,11 @@ protected:
DWORD GetModuleNameOfs(const char *szName);
char* GetModuleNameByOfs(DWORD ofs);
- ////////////////////////////////////////////////////////////////////////////
- // checker
-
- int PeekSegment(DWORD ofs, PVOID buf, int cbBytes);
- int ReadSegment(DWORD ofs, PVOID buf, int cbBytes);
- int ReadWrittenSegment(DWORD ofs, PVOID buf, int cbBytes);
- int SignatureValid(DWORD ofs, DWORD dwSignature);
- void FreeModuleChain();
-
- DWORD ConvertModuleNameOfs(DWORD ofsOld);
- void ConvertOldEvent(DBEvent*& dbei);
- int GetContactSettingWorker(MCONTACT contactID, LPCSTR szModule, LPCSTR szSetting, DBVARIANT *dbv, int isStatic);
- int WorkSettingsChain(DBContact *dbc, int firstTime);
- int WorkEventChain(DWORD ofsContact, DBContact *dbc, int firstTime);
+ int GetContactSettingWorker(MCONTACT contactID, LPCSTR szModule, LPCSTR szSetting, DBVARIANT *dbv, int isStatic);
- DWORD WriteSegment(DWORD ofs, PVOID buf, int cbBytes);
- DWORD WriteEvent(DBEvent *dbe);
- DWORD PeekEvent(DWORD ofs, DWORD dwContactID, DBEvent &dbe);
- void WriteOfsNextToPrevious(DWORD ofsPrev, DBContact *dbc, DWORD ofsNext);
- void FinishUp(DWORD ofsLast, DBContact *dbc);
DBCHeckCallback *cb;
- DWORD sourceFileSize, ofsAggrCur;
////////////////////////////////////////////////////////////////////////////
// encryption