Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
3fc5147b
Commit
3fc5147b
authored
May 16, 2017
by
Sylvestre Ledru
Committed by
Sylvestre Ledru
May 16, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
plugin.c (try_init_one_plugin): Fix ressource leaks (CID 726637)
From-SVN: r248088
parent
be742f1e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
1 deletions
+8
-1
gcc/ChangeLog
+4
-0
gcc/plugin.c
+4
-1
No files found.
gcc/ChangeLog
View file @
3fc5147b
2017-05-15 Sylvestre Ledru <sylvestre@debian.org>
plugin.c (try_init_one_plugin): Fix ressource leaks (CID 726637)
2017-05-15 Uros Bizjak <ubizjak@gmail.com>
PR target/80425
...
...
gcc/plugin.c
View file @
3fc5147b
...
...
@@ -617,6 +617,7 @@ try_init_one_plugin (struct plugin_name_args *plugin)
if
((
err
=
dlerror
())
!=
NULL
)
{
dlclose
(
dl_handle
);
error
(
"cannot find %s in plugin %s
\n
%s"
,
str_plugin_init_func_name
,
plugin
->
full_name
,
err
);
return
false
;
...
...
@@ -625,10 +626,12 @@ try_init_one_plugin (struct plugin_name_args *plugin)
/* Call the plugin-provided initialization routine with the arguments. */
if
((
*
plugin_init
)
(
plugin
,
&
gcc_version
))
{
dlclose
(
dl_handle
);
error
(
"fail to initialize plugin %s"
,
plugin
->
full_name
);
return
false
;
}
/* leak dl_handle on purpose to ensure the plugin is loaded for the
entire run of the compiler. */
return
true
;
}
...
...
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