mirror of
https://github.com/MariaDB/server.git
synced 2025-01-16 20:12:31 +01:00
Backport from the Falcon tree.
When opening/creating the transaction coordinator's log, if binlog is used, the tc log is the binlog so we use the binlog's name; otherwise we use the mmap-based log, named after the mandatory argument of the --log-tc option (meant for that). sql/log.cc: fixing wrong order of arguments to my_create() (3rd param is the desired modes of the file; "0" lead to no rights for anybody on the file). sql/mysqld.cc: When opening/creating the transaction coordinator's log, if binlog is used, the tc log is the binlog so we use the binlog's name; otherwise we use the mmap-based log, named after the mandatory argument of the --log-tc option (meant for that).
This commit is contained in:
parent
f6834c02ca
commit
9dfb1d9011
2 changed files with 2 additions and 2 deletions
|
@ -2523,7 +2523,7 @@ int TC_LOG_MMAP::open(const char *opt_name)
|
|||
goto err;
|
||||
if (using_heuristic_recover())
|
||||
return 1;
|
||||
if ((fd= my_create(logname, O_RDWR, 0, MYF(MY_WME))) < 0)
|
||||
if ((fd= my_create(logname, CREATE_MODE, O_RDWR, MYF(MY_WME))) < 0)
|
||||
goto err;
|
||||
inited=1;
|
||||
file_length= opt_tc_log_size;
|
||||
|
|
|
@ -3171,7 +3171,7 @@ server.");
|
|||
(TC_LOG *) &tc_log_mmap) :
|
||||
(TC_LOG *) &tc_log_dummy);
|
||||
|
||||
if (tc_log->open(opt_bin_logname))
|
||||
if (tc_log->open(opt_bin_log ? opt_bin_logname : opt_tc_log_file))
|
||||
{
|
||||
sql_print_error("Can't init tc log");
|
||||
unireg_abort(1);
|
||||
|
|
Loading…
Reference in a new issue