summaryrefslogtreecommitdiff
path: root/sql/sql_parse.cc
diff options
context:
space:
mode:
authorunknown <aelkin/elkin@koti.dsl.inet.fi>2007-10-03 13:43:56 +0300
committerunknown <aelkin/elkin@koti.dsl.inet.fi>2007-10-03 13:43:56 +0300
commit021c19ff1d77eb6325410775736ad7936a89d7bb (patch)
tree46212200aa6ad73ead533e2ddaa040e6b578ea19 /sql/sql_parse.cc
parent56fe8fc46b58f52d11a863f3771eee42c02ceacd (diff)
parent9c0448fa7ccbe29793e38b523bc3477be92e43cd (diff)
downloadmariadb-git-021c19ff1d77eb6325410775736ad7936a89d7bb.tar.gz
Merge aelkin@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl
into koti.dsl.inet.fi:/home/elkin/MySQL/TEAM/FIXES/5.0/bug26000_show_slave_status_when_no_active_mi sql/sql_parse.cc: Auto merged
Diffstat (limited to 'sql/sql_parse.cc')
-rw-r--r--sql/sql_parse.cc11
1 files changed, 10 insertions, 1 deletions
diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc
index 084bcfc3c76..f4ee2ffc0f7 100644
--- a/sql/sql_parse.cc
+++ b/sql/sql_parse.cc
@@ -2844,7 +2844,16 @@ mysql_execute_command(THD *thd)
if (check_global_access(thd, SUPER_ACL | REPL_CLIENT_ACL))
goto error;
pthread_mutex_lock(&LOCK_active_mi);
- res = show_master_info(thd,active_mi);
+ if (active_mi != NULL)
+ {
+ res = show_master_info(thd, active_mi);
+ }
+ else
+ {
+ push_warning(thd, MYSQL_ERROR::WARN_LEVEL_WARN, 0,
+ "the master info structure does not exist");
+ send_ok(thd);
+ }
pthread_mutex_unlock(&LOCK_active_mi);
break;
}