summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/modules/extra/m_pgsql.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modules/extra/m_pgsql.cpp b/src/modules/extra/m_pgsql.cpp
index a065b41b9..0f6ef2c85 100644
--- a/src/modules/extra/m_pgsql.cpp
+++ b/src/modules/extra/m_pgsql.cpp
@@ -540,7 +540,7 @@ SQLConn::~SQLConn()
bool SQLConn::DoConnect()
{
//ServerInstance->Log(DEBUG, "SQLConn::DoConnect()");
-
+
if(!(sql = PQconnectStart(MkInfoStr().c_str())))
{
Instance->Log(DEBUG, "Couldn't allocate PGconn structure, aborting: %s", PQerrorMessage(sql));
@@ -1309,5 +1309,6 @@ class ModulePgSQLFactory : public ModuleFactory
extern "C" void * init_module( void )
{
+ PQregisterThreadLock(pgthreadlock_t(1));
return new ModulePgSQLFactory;
}