This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug lto/64837] New: lto plugun doesn't call ld_plugin_release_input_file
- From: "hjl.tools at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 28 Jan 2015 14:24:12 +0000
- Subject: [Bug lto/64837] New: lto plugun doesn't call ld_plugin_release_input_file
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64837
Bug ID: 64837
Summary: lto plugun doesn't call ld_plugin_release_input_file
Product: gcc
Version: 5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: lto
Assignee: unassigned at gcc dot gnu.org
Reporter: hjl.tools at gmail dot com
CC: ccoutant at gcc dot gnu.org
Since lto plugin doesn't call ld_plugin_release_input_file,
plugin_maybe_claim in ld/plugin.c does
/* fd belongs to us, not the plugin; but we don't need it. */
close (file->fd);
It may not work for other plugins, like LLVM plugin. It
may also leak file descriptor when gold is used.