Fixed calling the wrong GetError(), causing misleading spew (part of bug 2698).

This commit is contained in:
David Anderson 2008-10-17 02:04:09 -05:00
parent 3c12db8637
commit 5a2f8afd33

View File

@ -85,7 +85,11 @@ void TQueryOp::RunThreadPart()
if (!BindParamsAndRun())
{
g_pSM->LogError(myself, "Failed SQL Query, Error: \"%s\" (Query id %i - client %i)", m_database->GetError(), m_type, m_client);
g_pSM->LogError(myself,
"Failed SQL Query, Error: \"%s\" (Query id %i - client %i)",
m_pQuery ? m_pQuery->GetError() : "NULL QUERY",
m_type,
m_client);
}
m_insertId = m_database->GetInsertID();