summaryrefslogtreecommitdiff
path: root/client/mysql.cc
diff options
context:
space:
mode:
Diffstat (limited to 'client/mysql.cc')
-rw-r--r--client/mysql.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/client/mysql.cc b/client/mysql.cc
index 2fa131b854a..fd63c0dc18e 100644
--- a/client/mysql.cc
+++ b/client/mysql.cc
@@ -2328,7 +2328,7 @@ com_status(String *buffer __attribute__((unused)),
(result=mysql_use_result(&mysql)))
{
MYSQL_ROW cur=mysql_fetch_row(result);
- tee_fprintf(stdout, "Current database:\t%s\n",cur[0]);
+ tee_fprintf(stdout, "Current database:\t%s\n", cur[0] ? cur[0] : "");
tee_fprintf(stdout, "Current user:\t\t%s\n",cur[1]);
(void) mysql_fetch_row(result); // Read eof
}