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
06a8412b
Commit
06a8412b
authored
Aug 28, 2021
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleanup: plugin unload
* reduce code duplication
parent
3050d5e8
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
18 deletions
+11
-18
sql/sql_plugin.cc
sql/sql_plugin.cc
+11
-18
No files found.
sql/sql_plugin.cc
View file @
06a8412b
...
@@ -1263,23 +1263,16 @@ static void plugin_deinitialize(struct st_plugin_int *plugin, bool ref_check)
...
@@ -1263,23 +1263,16 @@ static void plugin_deinitialize(struct st_plugin_int *plugin, bool ref_check)
remove_status_vars
(
show_vars
);
remove_status_vars
(
show_vars
);
}
}
if
(
plugin_type_deinitialize
[
plugin
->
plugin
->
type
])
plugin_type_init
deinit
=
plugin_type_deinitialize
[
plugin
->
plugin
->
type
];
{
if
(
!
deinit
)
if
((
*
plugin_type_deinitialize
[
plugin
->
plugin
->
type
])(
plugin
))
deinit
=
(
plugin_type_init
)(
plugin
->
plugin
->
deinit
);
if
(
deinit
&&
deinit
(
plugin
))
{
{
sql_print_error
(
"Plugin '%s' of type %s failed deinitialization"
,
sql_print_error
(
"Plugin '%s' of type %s failed deinitialization"
,
plugin
->
name
.
str
,
plugin_type_names
[
plugin
->
plugin
->
type
].
str
);
plugin
->
name
.
str
,
plugin_type_names
[
plugin
->
plugin
->
type
].
str
);
}
}
}
else
if
(
plugin
->
plugin
->
deinit
)
{
DBUG_PRINT
(
"info"
,
(
"Deinitializing plugin: '%s'"
,
plugin
->
name
.
str
));
if
(
plugin
->
plugin
->
deinit
(
plugin
))
{
DBUG_PRINT
(
"warning"
,
(
"Plugin '%s' deinit function returned error."
,
plugin
->
name
.
str
));
}
}
plugin
->
state
=
PLUGIN_IS_UNINITIALIZED
;
plugin
->
state
=
PLUGIN_IS_UNINITIALIZED
;
if
(
ref_check
&&
plugin
->
ref_count
)
if
(
ref_check
&&
plugin
->
ref_count
)
...
...
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