Fix release mode build failures

Fixed mxb_assert_message and one dcb_printf failure.
This commit is contained in:
Markus Mäkelä 2019-06-12 11:13:28 +03:00
parent a0fcf67993
commit 7470a58a32
No known key found for this signature in database
GPG Key ID: 72D48FCE664F7B19
3 changed files with 3 additions and 3 deletions

View File

@ -54,7 +54,7 @@ MXB_BEGIN_DECLS
#else /* SS_DEBUG */
#define mxb_assert(exp)
#define mxb_assert_message(exp, message)
#define mxb_assert_message(exp, fmt, ...)
#define MXB_AT_DEBUG(exp)

View File

@ -1598,7 +1598,7 @@ void dprintDCB(DCB* pdcb, DCB* dcb)
if (dcb->server)
{
string statusname = dcb->server->status_string();
if (!statusname.c_str())
if (!statusname.empty())
{
dcb_printf(pdcb, "\tServer status: %s\n", statusname.c_str());
}

View File

@ -61,7 +61,7 @@ MainWorker& MainWorker::get()
void MainWorker::add_task(const std::string& name, TASKFN func, void* pData, int frequency)
{
execute([=]() {
mxb_assert_message(m_tasks_by_name.find(name) == m_tasks_by_name.end(), name.c_str());
mxb_assert_message(m_tasks_by_name.find(name) == m_tasks_by_name.end(), "%s", name.c_str());
Task task(name.c_str(), func, pData, frequency);