From 35890cb243e1ba1f44fa6d69ccb9ba1e91cd1f94 Mon Sep 17 00:00:00 2001 From: XieHan Date: Wed, 26 Aug 2020 01:06:08 +0800 Subject: [PATCH] Fix the error message output of mysql tutorial. --- tutorial/tutorial-12-mysql_cli.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tutorial/tutorial-12-mysql_cli.cc b/tutorial/tutorial-12-mysql_cli.cc index 733cc4f1..fe6eb774 100644 --- a/tutorial/tutorial-12-mysql_cli.cc +++ b/tutorial/tutorial-12-mysql_cli.cc @@ -81,7 +81,9 @@ void mysql_callback(WFMySQLTask *task) if (task->get_state() != WFT_STATE_SUCCESS) { - fprintf(stderr, "task error = %d\n", task->get_error()); + fprintf(stderr, "error msg: %s\n", + WFGlobal::get_error_string(task->get_state(), + task->get_error())); return; }