mirror of
https://github.com/MariaDB/server.git
synced 2025-08-07 00:04:31 +03:00
Merge with 4.0.13
This commit is contained in:
@@ -997,7 +997,7 @@ int show_binlog_events(THD* thd)
|
||||
{
|
||||
LEX_MASTER_INFO *lex_mi = &thd->lex.mi;
|
||||
ha_rows event_count, limit_start, limit_end;
|
||||
my_off_t pos = lex_mi->pos;
|
||||
my_off_t pos = max(BIN_LOG_HEADER_SIZE, lex_mi->pos); // user-friendly
|
||||
char search_file_name[FN_REFLEN], *name;
|
||||
const char *log_file_name = lex_mi->log_file_name;
|
||||
pthread_mutex_t *log_lock = mysql_bin_log.get_log_lock();
|
||||
@@ -1025,12 +1025,6 @@ int show_binlog_events(THD* thd)
|
||||
if ((file=open_binlog(&log, linfo.log_file_name, &errmsg)) < 0)
|
||||
goto err;
|
||||
|
||||
if (pos < 4)
|
||||
{
|
||||
errmsg = "Invalid log position";
|
||||
goto err;
|
||||
}
|
||||
|
||||
pthread_mutex_lock(log_lock);
|
||||
my_b_seek(&log, pos);
|
||||
|
||||
|
Reference in New Issue
Block a user