diff options
author | Adam <Adam@anope.org> | 2012-05-08 18:04:49 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2012-05-08 18:04:49 -0400 |
commit | 820e4edc2bfc132a526e5c6db51d94f10ddc4542 (patch) | |
tree | a6daebbc9958f312475699a061a99ee533cd0858 /modules/extra/m_sqlite.cpp | |
parent | 25586f32467334f0366ce0b8bfe16e2d5e005851 (diff) |
Fixed some 100% cpu bugs with the new SQL stuff, and fixed sqlite+db_sql_live
Diffstat (limited to 'modules/extra/m_sqlite.cpp')
-rw-r--r-- | modules/extra/m_sqlite.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/modules/extra/m_sqlite.cpp b/modules/extra/m_sqlite.cpp index 4cf66cb5f..136e9d0dc 100644 --- a/modules/extra/m_sqlite.cpp +++ b/modules/extra/m_sqlite.cpp @@ -53,6 +53,8 @@ class SQLiteService : public SQLProvider SQLQuery GetTables(const Anope::string &prefix); Anope::string BuildQuery(const SQLQuery &q); + + Anope::string FromUnixtime(time_t); }; class ModuleSQLite : public Module @@ -297,5 +299,10 @@ Anope::string SQLiteService::BuildQuery(const SQLQuery &q) return real_query; } +Anope::string SQLiteService::FromUnixtime(time_t t) +{ + return "datetime('" + stringify(t) + "', 'unixepoch')"; +} + MODULE_INIT(ModuleSQLite) |