Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
c84737d6
Commit
c84737d6
authored
Oct 11, 2004
by
guilhem@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge gbichot@bk-internal.mysql.com:/home/bk/mysql-4.0
into mysql.com:/home/mysql_src/mysql-4.0
parents
d2a55484
13af58aa
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
2 deletions
+38
-2
mysql-test/r/rpl_commit_after_flush.result
mysql-test/r/rpl_commit_after_flush.result
+13
-0
mysql-test/t/rpl_commit_after_flush.test
mysql-test/t/rpl_commit_after_flush.test
+17
-0
sql/lock.cc
sql/lock.cc
+8
-2
No files found.
mysql-test/r/rpl_commit_after_flush.result
0 → 100644
View file @
c84737d6
slave stop;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
reset master;
reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
slave start;
create table t1 (a int) type=innodb;
begin;
insert into t1 values(1);
flush tables with read lock;
commit;
unlock tables;
drop table t1;
mysql-test/t/rpl_commit_after_flush.test
0 → 100644
View file @
c84737d6
source
include
/
master
-
slave
.
inc
;
source
include
/
have_innodb
.
inc
;
create
table
t1
(
a
int
)
type
=
innodb
;
begin
;
insert
into
t1
values
(
1
);
flush
tables
with
read
lock
;
commit
;
save_master_pos
;
connection
slave
;
sync_with_master
;
# cleanup
connection
master
;
unlock
tables
;
drop
table
t1
;
save_master_pos
;
connection
slave
;
sync_with_master
;
sql/lock.cc
View file @
c84737d6
...
...
@@ -751,9 +751,15 @@ bool wait_if_global_read_lock(THD *thd, bool abort_on_refresh, bool is_not_commi
{
if
(
thd
->
global_read_lock
)
// This thread had the read locks
{
my_error
(
ER_CANT_UPDATE_WITH_READLOCK
,
MYF
(
0
));
if
(
is_not_commit
)
my_error
(
ER_CANT_UPDATE_WITH_READLOCK
,
MYF
(
0
));
(
void
)
pthread_mutex_unlock
(
&
LOCK_open
);
DBUG_RETURN
(
1
);
/*
We allow FLUSHer to COMMIT; we assume FLUSHer knows what it does.
This allowance is needed to not break existing versions of innobackup
which do a BEGIN; INSERT; FLUSH TABLES WITH READ LOCK; COMMIT.
*/
DBUG_RETURN
(
is_not_commit
);
}
old_message
=
thd
->
enter_cond
(
&
COND_refresh
,
&
LOCK_open
,
"Waiting for release of readlock"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment