[GOLD] Fix spurious "plugin needed to handle lto object" warnings
authorAlan Modra <amodra@gmail.com>
Fri, 20 Sep 2019 05:22:54 +0000 (14:52 +0930)
committerAlan Modra <amodra@gmail.com>
Fri, 20 Sep 2019 08:08:01 +0000 (17:38 +0930)
commit0a9fdbbfd319c09e48ac176fd6386b445534cf42
tree34bbb979d8d83fe52a9fbf43893cb7eed6b53f7f
parent64dde846bd6915a5a276389c00c286a49c982395
[GOLD] Fix spurious "plugin needed to handle lto object" warnings

lto_slim_object_ was unitialized.  I also thought it worth adding
a sanity check on the .gnu.lto_.lto.* section size, and made some
other tidies.

PR 24768
* layout.cc (Layout::Layout): Init lto_slim_object_.
* object.cc (Sized_relobj_file::do_layout): Wrap overlong line.
Don't use C cast.  Validate section size.  Don't copy contents.

(cherry picked from commit 4c51dacacf8a97194a1241ad5e1cbf7be00a59a3)
gold/ChangeLog
gold/layout.cc
gold/object.cc