summaryrefslogtreecommitdiff
path: root/sql/sql_yacc.yy
diff options
context:
space:
mode:
authorMonty <monty@mariadb.org>2015-07-15 16:27:14 +0300
committerMonty <monty@mariadb.org>2015-07-16 10:36:58 +0300
commit872a953b228e93553ed056d8fa035ff06e884bc8 (patch)
treea90958d21c610b2517705ab79666aacd8c837e84 /sql/sql_yacc.yy
parentdf0498fd76897c0e034ab3f0598972f0e2419b02 (diff)
downloadmariadb-git-872a953b228e93553ed056d8fa035ff06e884bc8.tar.gz
MDEV-8469 Add RESET MASTER TO x to allow specification of binlog file nr
Other things: - Avoid calling init_and_set_log_file_name() when opening binary log. - Remove newlines early when reading from index file. - Ensure that reset_logs() will work even if thd is 0 (Can happen on startup) - Added thd to sart_slave_threads() for better error handling.
Diffstat (limited to 'sql/sql_yacc.yy')
-rw-r--r--sql/sql_yacc.yy15
1 files changed, 14 insertions, 1 deletions
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy
index 55041b1e172..811ee4f97d5 100644
--- a/sql/sql_yacc.yy
+++ b/sql/sql_yacc.yy
@@ -13037,7 +13037,12 @@ reset_option:
SLAVE { Lex->type|= REFRESH_SLAVE; }
optional_connection_name
slave_reset_options { }
- | MASTER_SYM { Lex->type|= REFRESH_MASTER; }
+ | MASTER_SYM
+ {
+ Lex->type|= REFRESH_MASTER;
+ Lex->next_binlog_file_number= 0;
+ }
+ master_reset_options
| QUERY_SYM CACHE_SYM { Lex->type|= REFRESH_QUERY_CACHE;}
;
@@ -13046,6 +13051,14 @@ slave_reset_options:
| ALL { Lex->reset_slave_info.all= true; }
;
+master_reset_options:
+ /* empty */ {}
+ | TO_SYM ulong_num
+ {
+ Lex->next_binlog_file_number = $2;
+ }
+ ;
+
purge:
PURGE
{