aboutsummaryrefslogtreecommitdiffstats
path: root/util/sql.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2014-12-11 09:18:39 +0100
committerKim Alvefur <zash@zash.se>2014-12-11 09:18:39 +0100
commit655e1cde09f9ffb942f698b3869b1616ef11d70c (patch)
tree5be4e89291fa09d4adf85485d8cf2193d4868c3f /util/sql.lua
parentf361945594fd28aced85bb500332d186f171e7a5 (diff)
downloadprosody-655e1cde09f9ffb942f698b3869b1616ef11d70c.tar.gz
prosody-655e1cde09f9ffb942f698b3869b1616ef11d70c.zip
mod_storage_sql2, util.sql: Set character encoding on every connect
Diffstat (limited to 'util/sql.lua')
-rw-r--r--util/sql.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/util/sql.lua b/util/sql.lua
index 5a1dda5d..453597da 100644
--- a/util/sql.lua
+++ b/util/sql.lua
@@ -156,6 +156,7 @@ function engine:connect()
dbh:autocommit(false); -- don't commit automatically
self.conn = dbh;
self.prepared = {};
+ self:set_encoding();
return true;
end
function engine:execute(sql, ...)