Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Class Members | File Members | Related Pages

db.h File Reference

Go to the source code of this file.

Functions

void saveNickData (void)
 Saves the NickServ database to disk.

void saveChanData (RegChanList *)
 Saves the ChanServ database to disk.

void readNickData (void)
 Loads the NickServ database from disk.

void readChanData (void)
 Loads the ChanServ database from disk.

void saveMemoData (void)
 Saves the Memo database to disk.

void readMemoData (void)
 Loads the memo database from disk.

void saveInfoData (void)
 Saves the InfoServ database to disk.

void readInfoData (void)
 Loads the InfoServ database from disk.

void readTriggerData (void)
 Loads the clone rule database from disk.

void saveTriggerData (void)
 Saves the Clone rule database to disk.


Detailed Description

Services database function prototypes

Definition in file db.h.


Function Documentation

void readChanData void   ) 
 

Loads the ChanServ database from disk.

Bug:
XXX verify this works

Definition at line 625 of file db.c.

References addChanAkick(), addChanOp(), cakicklist_struct::added, addRegChan(), CENCRYPT, ChanServ, database_struct::cs, dbLine, fromBase64(), getRegChanData(), getRegNickData(), initRegChanData(), cakicklist_struct::mask, mostchans, caccesslist_struct::nickId, oalloc(), parse_getarg(), cakicklist_struct::reason, sSend(), sshutdown(), state, strncpyzt, caccesslist_struct::uflags, unexpected_eof(), and xorit().

Referenced by main().

void readInfoData void   ) 
 

Loads the InfoServ database from disk.

There was still a crash bug in what was here before... cleaning this up .. allocate memory when it's needed, don't allocate it in the beginning and give it up later if superflous in a linked list load. -Mysidia

Bug:
XXX be nicer here...

Definition at line 1213 of file db.c.

References dbLine, dbReadString(), Newsitem::importance, database_struct::is, is_last_post_time, is_listhead, Newsitem::next, oalloc(), parse_getarg(), SomeNews, sshutdown(), state, strncpyzt, and unexpected_eof().

Referenced by main().

void readMemoData void   ) 
 

Loads the memo database from disk.

Bug:
XXX be nicer here...

Increment the arguments.. we REALLY need to fix the dbs

Increment the argument 1, we need to fix the db

Definition at line 919 of file db.c.

References memoblocklist_struct::blockId, dbLine, DEBUGCHAN, _memolist::flags, _memolist::from, getRegNickData(), LIST_ENTRY_INIT, LIST_INSERT_HEAD, MEMO_UNREAD, MemoServ, _memolist::memotxt, database_struct::ms, memoblocklist_struct::next, oalloc(), parse_getarg(), _memolist::realto, _memolist::sent, sSend(), sshutdown(), state, strncpyzt, _memolist::to, and unexpected_eof().

Referenced by readNickData().

void readNickData void   ) 
 

Loads the NickServ database from disk.

Bug:
XXX make a nicer error here!

Definition at line 262 of file db.c.

References ADD_MEMO_BOX, addAccItem(), addOpData(), addRegNick(), assert, corelog, dbLine, DEBUGCHAN, fromBase64(), getRegNickData(), logDump(), NENCRYPT, database_struct::ns, oalloc(), OROOT, OSERVOP, parse_getarg(), readMemoData(), SetDynBuffer(), sSend(), sshutdown(), state, strncpyzt, unexpected_eof(), and xorit().

Referenced by main().

void readTriggerData void   ) 
 

Loads the clone rule database from disk.

Bug:
XXX be nicer here...

Definition at line 1102 of file db.c.

References AddCrule(), CloneRule, corelog, dbLine, DEBUGCHAN, trigger_rule::flags, trigger_rule::kill_msg, logDump(), trigger_rule::mask, NewCrule(), OperServ, parse_getarg(), sSend(), state, strncpyzt, trigger_rule::trigger, database_struct::trigger, unexpected_eof(), trigger_rule::utrigger, and trigger_rule::warn_msg.

Referenced by main().

void saveInfoData void   ) 
 

Saves the InfoServ database to disk.

Bug:
Huh? Why check for NULL -twice- ?

Definition at line 1177 of file db.c.

References Newsitem::content, corelog, dbWriteString(), Newsitem::from, Newsitem::header, Newsitem::importance, InfoServ, database_struct::is, is_listhead, LOGCHAN, logDump(), myname, Newsitem::next, SomeNews, sSend(), and Newsitem::timestamp.

Referenced by is_save(), and sshutdown().


Generated at Sat Oct 25 20:56:11 2003 for Services using Doxygen.
Services Copyr. 1996-2001 Chip Norkus, Max Byrd, Greg Poma, Michael Graff, James Hess, Dafydd James. All rights reserved See LICENSE for licensing information.