mirror of
https://github.com/mangosfour/server.git
synced 2025-12-23 07:37:01 +00:00
[11928] Some warning fixes
This commit is contained in:
parent
7c827733f5
commit
c6a751134c
18 changed files with 28 additions and 38 deletions
|
|
@ -307,7 +307,7 @@ QueryResult* Database::PQuery(const char *format,...)
|
|||
if(res==-1)
|
||||
{
|
||||
sLog.outError("SQL Query truncated (and not execute) for format: %s",format);
|
||||
return false;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return Query(szQuery);
|
||||
|
|
@ -326,7 +326,7 @@ QueryNamedResult* Database::PQueryNamed(const char *format,...)
|
|||
if(res==-1)
|
||||
{
|
||||
sLog.outError("SQL Query truncated (and not execute) for format: %s",format);
|
||||
return false;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return QueryNamed(szQuery);
|
||||
|
|
|
|||
|
|
@ -337,7 +337,7 @@ bool MySqlPreparedStatement::prepare()
|
|||
m_stmt = mysql_stmt_init(m_pMySQLConn);
|
||||
if (!m_stmt)
|
||||
{
|
||||
sLog.outError("SQL: mysql_stmt_init()() failed ");
|
||||
sLog.outError("SQL: mysql_stmt_init() failed ");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -72,6 +72,8 @@ class MANGOS_DLL_SPEC MySQLConnection : public SqlConnection
|
|||
MySQLConnection(Database& db) : SqlConnection(db), mMysql(NULL) {}
|
||||
~MySQLConnection();
|
||||
|
||||
//! Initializes Mysql and connects to a server.
|
||||
/*! infoString should be formated like hostname;username;password;database. */
|
||||
bool Initialize(const char *infoString);
|
||||
|
||||
QueryResult* Query(const char *sql);
|
||||
|
|
@ -102,9 +104,6 @@ class MANGOS_DLL_SPEC DatabaseMysql : public Database
|
|||
DatabaseMysql();
|
||||
~DatabaseMysql();
|
||||
|
||||
//! Initializes Mysql and connects to a server.
|
||||
/*! infoString should be formated like hostname;username;password;database. */
|
||||
|
||||
// must be call before first query in thread
|
||||
void ThreadStart();
|
||||
// must be call before finish thread run
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue