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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
d415f600
Commit
d415f600
authored
Nov 20, 2023
by
Kristian Nielsen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-32844: THD::rli_fake/rgi_fake not cleared on new connection
Signed-off-by:
Kristian Nielsen
<
knielsen@knielsen-hq.org
>
parent
7aca66a3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
11 deletions
+38
-11
mysql-test/suite/sys_vars/r/pseudo_slave_mode_notembedded.result
...est/suite/sys_vars/r/pseudo_slave_mode_notembedded.result
+14
-0
mysql-test/suite/sys_vars/t/pseudo_slave_mode_notembedded.test
...-test/suite/sys_vars/t/pseudo_slave_mode_notembedded.test
+20
-0
sql/sql_class.cc
sql/sql_class.cc
+4
-11
No files found.
mysql-test/suite/sys_vars/r/pseudo_slave_mode_notembedded.result
0 → 100644
View file @
d415f600
'### MDEV-32844: THD::rli_fake/rgi_fake not cleared on new connection'
connect con1,localhost,root,,;
BINLOG '
6ENbZQ8BAAAA/AAAAAABAAAAAAQAMTAuMTEuNi1NYXJpYURCLWRlYnVnLWxvZwAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAADoQ1tlEzgNAAgAEgAEBAQEEgAA5AAEGggAAAAICAgCAAAACgoKAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAEEwQADQgICAoKCgGbvv33
';
disconnect con1;
connect con1,localhost,root,,;
SET SESSION pseudo_slave_mode= 1;
disconnect con1;
connection default;
mysql-test/suite/sys_vars/t/pseudo_slave_mode_notembedded.test
0 → 100644
View file @
d415f600
--
source
include
/
not_embedded
.
inc
--
source
include
/
load_sysvars
.
inc
--
echo
'### MDEV-32844: THD::rli_fake/rgi_fake not cleared on new connection'
--
connect
(
con1
,
localhost
,
root
,,)
BINLOG
'
6ENbZQ8BAAAA/AAAAAABAAAAAAQAMTAuMTEuNi1NYXJpYURCLWRlYnVnLWxvZwAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAADoQ1tlEzgNAAgAEgAEBAQEEgAA5AAEGggAAAAICAgCAAAACgoKAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAEEwQADQgICAoKCgGbvv33
'
;
--
disconnect
con1
--
connect
(
con1
,
localhost
,
root
,,)
# The bug was that the THD::rli_fake was not cleared when the THD is re-used
# for the new connection, and we would get a warning from the following
# statement.
SET
SESSION
pseudo_slave_mode
=
1
;
--
disconnect
con1
--
connection
default
sql/sql_class.cc
View file @
d415f600
...
...
@@ -1593,6 +1593,10 @@ void THD::free_connection()
vio_delete
(
net
.
vio
);
net
.
vio
=
nullptr
;
net_end
(
&
net
);
delete
(
rgi_fake
);
rgi_fake
=
NULL
;
delete
(
rli_fake
);
rli_fake
=
NULL
;
#endif
if
(
!
cleanup_done
)
cleanup
();
...
...
@@ -1695,17 +1699,6 @@ THD::~THD()
dbug_sentry
=
THD_SENTRY_GONE
;
#endif
#ifndef EMBEDDED_LIBRARY
if
(
rgi_fake
)
{
delete
rgi_fake
;
rgi_fake
=
NULL
;
}
if
(
rli_fake
)
{
delete
rli_fake
;
rli_fake
=
NULL
;
}
if
(
rgi_slave
)
rgi_slave
->
cleanup_after_session
();
my_free
(
semisync_info
);
...
...
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