From: Petr Machata Date: Tue, 6 Apr 2010 12:17:41 +0000 (+0200) Subject: Fix for the same X-Git-Tag: elfutils-0.146~21^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d7b12c622c06fd592b74a8ac4eb4fbdac42699b5;p=thirdparty%2Felfutils.git Fix for the same * Initialize data.s for data that do not need a conversion. --- diff --git a/libelf/ChangeLog b/libelf/ChangeLog index b0cff67c3..1fbdf4ccf 100644 --- a/libelf/ChangeLog +++ b/libelf/ChangeLog @@ -1,3 +1,8 @@ +2010-04-01 Petr Machata + + * elf_getdata.c (__elf_getdata_rdlock): Initialize data.s for data + that do not need a conversion. + 2010-03-11 Roland McGrath * elf.h: Update from glibc. diff --git a/libelf/elf_getdata.c b/libelf/elf_getdata.c index e083b033f..5a718f82e 100644 --- a/libelf/elf_getdata.c +++ b/libelf/elf_getdata.c @@ -467,9 +467,12 @@ __elf_getdata_rdlock (scn, data) scn->rawdata.d.d_size, scn->rawdata.d.d_type); } else - /* This is an empty or NOBITS section. There is no buffer but - the size information etc is important. */ - scn->data_list.data.d = scn->rawdata.d; + { + /* This is an empty or NOBITS section. There is no buffer but + the size information etc is important. */ + scn->data_list.data.d = scn->rawdata.d; + scn->data_list.data.s = scn; + } scn->data_list_rear = &scn->data_list; }