summaryrefslogtreecommitdiff
path: root/lib/rbot/registry.rb
diff options
context:
space:
mode:
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2006-08-03 17:35:15 +0000
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2006-08-03 17:35:15 +0000
commit9541057a74e533127377dfee4d3bc4831c564f8e (patch)
tree2e33a1bf2a03332e7ed44e2852e3b6517b9a97ad /lib/rbot/registry.rb
parent604729f561bde31de865c29042b579e84a266110 (diff)
Make keywords.rb into a plugin and sync with 0.9.10
Diffstat (limited to 'lib/rbot/registry.rb')
-rw-r--r--lib/rbot/registry.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/rbot/registry.rb b/lib/rbot/registry.rb
index e679722a..cb59306c 100644
--- a/lib/rbot/registry.rb
+++ b/lib/rbot/registry.rb
@@ -27,14 +27,14 @@ module Irc
}
old.close
new.close
- File.delete("#{@bot.botclass}/registry.db")
+ File.rename("#{@bot.botclass}/registry.db", "#{@bot.botclass}/registry.db.old")
end
end
def upgrade_data2
if File.exist?("#{@bot.botclass}/plugin_registry.db")
Dir.mkdir("#{@bot.botclass}/registry") unless File.exist?("#{@bot.botclass}/registry")
- env = BDB::Env.open("#{@bot.botclass}", BDB::INIT_TRANSACTION | BDB::CREATE | BDB::RECOVER)
+ env = BDB::Env.open("#{@bot.botclass}", BDB::INIT_TRANSACTION | BDB::CREATE | BDB::RECOVER)# | BDB::TXN_NOSYNC)
dbs = Hash.new
log "upgrading previous (rbot 0.9.9 or earlier) plugin registry to new split format"
old = BDB::CIBtree.open("#{@bot.botclass}/plugin_registry.db", nil,