ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/Deliantra-Client/DC/DB.pm
(Generate patch)

Comparing deliantra/Deliantra-Client/DC/DB.pm (file contents):
Revision 1.30 by root, Thu Dec 27 18:35:56 2007 UTC vs.
Revision 1.31 by root, Thu Jan 10 23:02:19 2008 UTC

1=head1 NAME 1=head1 NAME
2 2
3DC::DB - async. database and filesystem access for cfplus 3DC::DB - async. database and filesystem access for deliantra
4 4
5=head1 SYNOPSIS 5=head1 SYNOPSIS
6 6
7 use DC::DB; 7 use DC::DB;
8 8
22use Config; 22use Config;
23use BDB; 23use BDB;
24 24
25use DC; 25use DC;
26 26
27our $DBDIR = "cfplus-" . BDB::VERSION . "-$Config{archname}"; 27our $ODBDIR = "cfplus-" . BDB::VERSION . "-$Config{archname}";
28our $DBDIR = "client-" . BDB::VERSION . "-$Config{archname}";
28our $DB_HOME = "$Deliantra::VARDIR/$DBDIR"; 29our $DB_HOME = "$Deliantra::VARDIR/$DBDIR";
29 30
31if (!-e $DB_HOME and -e "$Deliantra::VARDIR/$ODBDIR") {
32 rename "$Deliantra::VARDIR/$ODBDIR", $DB_HOME;
33 print STDERR "INFO: moved old database from $Deliantra::VARDIR/$ODBDIR to $DB_HOME\n";
34}
35
30if (!-e $DB_HOME and -e "$Deliantra::OLDDIR/$DBDIR") { 36if (!-e $DB_HOME and -e "$Deliantra::OLDDIR/$ODBDIR") {
31 rename "$Deliantra::OLDDIR/$DBDIR", $DB_HOME; 37 rename "$Deliantra::OLDDIR/$DBDIR", $DB_HOME;
32 print STDERR "INFO: moved old database from $Deliantra::OLDDIR/$DBDIR to $DB_HOME\n"; 38 print STDERR "INFO: moved old database from $Deliantra::OLDDIR/$ODBDIR to $DB_HOME\n";
33} 39}
34 40
35BDB::max_poll_time 0.03; 41BDB::max_poll_time 0.03;
36 42
37our $DB_ENV; 43our $DB_ENV;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines