Commit 3734dfb3 authored by Olivier Bertrand's avatar Olivier Bertrand

- MySQL connection was not close if mysql_real_connect failed.

modified:
  storage/connect/myconn.cpp
parent 073b0e77
...@@ -308,6 +308,7 @@ int MYSQLC::Open(PGLOBAL g, const char *host, const char *db, ...@@ -308,6 +308,7 @@ int MYSQLC::Open(PGLOBAL g, const char *host, const char *db,
#else // !_DEBUG #else // !_DEBUG
sprintf(g->Message, "(%d) %s", mysql_errno(m_DB), mysql_error(m_DB)); sprintf(g->Message, "(%d) %s", mysql_errno(m_DB), mysql_error(m_DB));
#endif // !_DEBUG #endif // !_DEBUG
mysql_close(m_DB);
m_DB = NULL; m_DB = NULL;
return RC_FX; return RC_FX;
} // endif mysql_real_connect } // endif mysql_real_connect
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment