libctf: ctf_dwarf_convert: initialize derr to NULL
commitf1a5f8297bdf98acce5b55b9907b2d54ab7429d7
authorLauri Tirkkonen <lotheac@iki.fi>
Tue, 11 Jun 2019 13:59:19 +0000 (11 16:59 +0300)
committerLauri Tirkkonen <lotheac@iki.fi>
Sat, 21 Sep 2019 07:33:52 +0000 (21 10:33 +0300)
tree8d951865bf34fc9bc649e0e672cc2f977ad2ce18
parentff15aabeaaeb998af400d1544295c158157c2c29
libctf: ctf_dwarf_convert: initialize derr to NULL

the error reporting mechanism seems to rely on the called functions
allocating a new Dwarf_Error_s structure via _dwarf_error. however, if
that doesn't happen and we hit an error path in the calling code, we can
end up calling dwarf_errmsg with an uninitialized pointer value.
usr/src/lib/libctf/common/ctf_dwarf.c