12019-02-24  Mark Wielaard  <mark@klomp.org>
2
3	* gelf_xlate.c (__elf_xfctstof): Remove alias.
4	* libelfP.h (__elf_xfctstof): Remove definition.
5
62019-02-24  Mark Wielaard  <mark@klomp.org>
7
8	* elf32_fsize.c (local_strong_alias): Remove definition.
9	(msize): Remove alias.
10	* libelfP.h (__elf32_msize): Remove definition.
11	(__elf64_msize): Likewise.
12
132019-02-21  Mark Wielaard  <mark@klomp.org>
14
15	* common.h (determine_kind): Only accept EV_CURRENT.
16	* elf32_fsize.c (fsize): Just check version is EV_CURRENT.
17	Use __libelf_type_size without version dimension.
18	* elf32_updatefile.c (updatemmap): Define fctp from __elf_xfctstom
19	without version dimension.
20	(updatefile): Likewise.
21	* elf32_updatenull.c (default_ehdr): Check e_version is EV_CURRENT.
22	(updatenull_wrlock): Check d_version is EV_CURRENT.
23	(elf32_xlatetof): Likewise. And get recsize without version
24	dimension from __elf_xfctstom.
25	(elf32_xlatetom): Likewise.
26	* elf_begin.c (elf_begin): Check __libelf_version is EV_CURRENT.
27	* elf_compress.c (__libelf_reset_rawdata): Set d_version to
28	EV_CURRENT.
29	* elf_getdata.c (shtype_map): Remove version dimension.
30	(__libelf_type_aligns): Likewise.
31	(__libelf_data_type): Use shtype_map without version dimension.
32	(convert_data): Remove unused version argument. Get fp from
33	__elf_xfctstom without version dimensions.
34	(__libelf_set_data_list_rdlock): Call convert_data without version.
35	* elf_getdata_rawchunk.c (elf_getdata_rawchunk): Call __elfcfctstom
36	conversion function without version dimensions. Set d_version to
37	EV_CURRENT.
38	* elf_newdata.c (elf_newdata): Set d_version to EV_CURRENT.
39	* elf_version.c (__libelf_version_initialized): Removed.
40	(__libelf_version): Initialized to EV_NONE.
41	(elf_version): Always return EV_CURRENT for EV_NONE version.
42	Only accept (and return) EV_CURRENT as version.
43	* gelf_fsize.c (__libelf_type_sizes): Remove version dimension.
44	(gelf_fsize): Only accept EV_CURRENT as version.
45	Use __libelf_type_sizes without version dimension.
46	* gelf_xlate.c (__elf_xftstom): Remove version dimensions.
47	* libelfP.h (__elf_xfctstom): Defined without version dimensions.
48	(__elf_xfctstof): Likewise.
49	(__libelf_type_sizes): Define without version dimension.
50	(elf_typesize): Define using __libelf_type_sizes without version
51	dimension.
52	(__libelf_version_initialized): Remove definition.
53	(__libelf_version): Add definition.
54	(LIBELF_EV_IDX): Removed define.
55	(__libelf_type_aligns): Remove version dimension.
56	* nlist.c (nlist): Call elf_version unconditionally.
57
582019-02-19  Mark Wielaard  <mark@klomp.org>
59
60	* elf_compress.c (do_deflate_cleanup): Remove ei_data argument,
61	check cdatap is not NULL before calling free.
62	(deflate_cleanup): Add cdata as argument.
63	(__libelf_compress): Also check whether the d_size is not zero
64	before converting data. Call deflate_cleanup with an extra
65	argument depending on whether there is converted data to free.
66	Always allocate allocate at least one byte for buf_out.
67
682019-02-14  Mark Wielaard  <mark@klomp.org>
69
70	* elf_begin.c (read_long_names): Make sure ar_size is properly
71	terminated. Sanity check len early if we can.
72
732019-01-18  Mark Wielaard  <mark@klomp.org>
74
75	* Makefile.am (INSTALL_ELFH): Add elf.h to include_HEADERS when
76	defined, otherwise (the default) add elf.h to noinst_HEADERS.
77
782019-01-16  Mark Wielaard  <mark@klomp.org>
79
80	* note_xlate.h (elf_cvt_note): Check n_namesz and n_descsz don't
81	overflow note_len into note header.
82
832018-11-17  Mark Wielaard  <mark@klomp.org>
84
85	* elf32_updatefile.c (updatemmap): Make sure to call convert
86	function on a properly aligned destination.
87
882018-11-16  Mark Wielaard  <mark@klomp.org>
89
90	* libebl.h (__elf32_msize): Mark with const attribute.
91	(__elf64_msize): Likewise.
92
932018-11-13  Mark Wielaard  <mark@klomp.org>
94
95	* elf_getdata.c (__libelf_set_rawdata_wrlock): Explicitly set the
96	alignment of SHF_COMPRESSED data to the alignment of ELF_T_CHDR.
97	* elf_compress.c (elf_compress): After compression set sh_addralign
98	to the alignment of ELF_T_CHDR.
99
1002018-11-09  Mark Wielaard  <mark@klomp.org>
101
102	* elf_compress_gnu.c (elf_compress_gnu): Use elf_getdata.
103
1042018-11-12  Mark Wielaard  <mark@klomp.org>
105
106	* elf-knowledge.c (ELF_NOTE_GNU_BUILD_ATTRIBUTE_PREFIX): New define.
107	(NT_GNU_BUILD_ATTRIBUTE_{OPEN,FUNC}): Likewise.
108	(GNU_BUILD_ATTRIBUTE_TYPE_{NUMERIC,STRING,BOOL_TRUE,BOOL_FALSE}):
109	Likewise.
110	(GNU_BUILD_ATTRIBUTE_{VERSION,STACK_PROT,RELRO,STACK_SIZE,TOOL,ABI,
111	PIC,SHORT_ENUM}): Likewise.
112
1132018-11-09  Mark Wielaard  <mark@klomp.org>
114
115	* elf_compress.c (__libelf_reset_rawdata): Make rawdata change
116	explicit by calling __libelf_set_data_list.
117	* elf_getdata.c (convert_data): Don't convert if type is ELF_T_BYTE
118	even if endianness is different.
119
1202018-10-18  Mark Wielaard  <mark@klomp.org>
121
122	* libelf.h (Elf_Type): Add ELF_T_NHDR8.
123	* libelfP.h (__libelf_data_type): Add align argument.
124	(NOTE_ALIGN): Split into...
125	(NOTE_ALIGN4): ... and ...
126	(NOTE_ALIGN8): this.
127	* elf32_xlatetom.c (xlatetom): Recognize both ELF_T_NHDR and
128	ELF_T_NHDR8.
129	* elf_compress.c (elf_compress): Pass zdata_align to
130	__libelf_data_type.
131	* elf_compress_gnu.c (elf_compress_gnu): Pass sh_addralign to
132	__libelf_data_type.
133	* elf_getdata.c (shtype_map): Add ELF_T_NHDR8.
134	(__libelf_data_type): Take align as extra argument, use it to
135	determine Elf_Type.
136	(__libelf_set_rawdata_wrlock): Recognize ELF_T_NHDR8. Pass align to
137	__libelf_data_type.
138	* gelf_fsize.c (__libelf_type_sizes): Add ELF_T_NHDR8.
139	* gelf_getnote.c (gelf_getnote): Use Elf_Type of Elf_Data to calculate
140	padding.
141	* gelf_xlate.c (__elf_xfctstom): Set ELF_T_NHDR to elf_cvt_note4,
142	add ELF_T_NHDR8.
143	* note_xlate.h (elf_cvt_note): Take nhdr8 argument and use it to
144	determine padding.
145	(elf_cvt_note4): New function.
146	(elf_cvt_note8): Likewise.
147
1482018-09-13  Mark Wielaard  <mark@klomp.org>
149
150	* elf32_updatefile.c (updatemmap): Use shnum, not ehdr->e_shnum.
151	* elf_getscn.c (elf_getscn): Create section zero if it is requested,
152	but doesn't exist yet.
153
1542018-09-12  Mark Wielaard  <mark@klomp.org>
155
156	* elf32_updatefile.c (updatemmap): Use memmove, not memcpy.
157	* elf_update.c (write_file): Try to mremap if file needs to be
158	extended.
159
1602018-08-18  Mark Wielaard  <mark@klomp.org>
161
162	* libelf.h (elf_compress_gnu): Add documentation about
163	interaction between SHF_COMPRESED and elf_compress_gnu.
164	* elf_compress_gnu.c (elf_compress_gnu): Return error if section
165	sh_flags has SHF_COMPRESSED set.
166
1672018-07-27  Mark Wielaard  <mark@klomp.org>
168
169	* libelf.h (elf_getshdrstrndx): Fix documentation.
170	(elf_getshstrndx): Likewise.
171
1722018-06-19  Mark Wielaard  <mark@klomp.org>
173
174	* libelfP.h (__libelf_type_align): Remove !ALLOW_UNALIGNED guard.
175	* elf_getdata.c (__libelf_type_aligns): Likewise.
176	(convert_data): Remove ALLOW_UNALIGNED check.
177	* elf_getdata_rawchunk.c (elf_getdata_rawchunk): Likewise.
178
1792018-06-21  Mark Wielaard  <mark@klomp.org>
180
181	* elf.h: Update from glibc.
182
1832018-04-19  Andreas Schwab  <schwab@suse.de>
184
185	* elf.h: Update from glibc.
186
1872018-02-16  Mark Wielaard  <mark@klomp.org>
188
189	* elf.h: Update from glibc.
190
1912018-02-09  Joshua Watt  <JPEWhacker@gmail.com>
192
193	* elf32_updatenull.c (updatenull_wrlock): Use FALLTHROUGH macro
194	instead of comment.
195	* elf_begin.c (read_unmmaped_file): Likewise.
196	(elf_begin): Likewise.
197	* elf_cntl.c (elf_cntl): Likewise.
198
1992017-10-04  Mark Wielaard  <mark@klomp.org>
200
201	* elf_begin.c (file_read_elf): Skip sanity checking e_shoff if scncnt
202	is zero, we won't use it then.
203
2042017-10-04  Mark Wielaard  <mark@klomp.org>
205
206	* libelfP.h: Add ELF_E_INVALID_ELF to error values enum.
207	* elf_error.c (ELF_E_INVALID_ELF_IDX): New define. Use it as value
208	for ELF_E_INVALID_ELF in msgidx.
209	* elf_getshdrstrndx.c (elf_getshdrstrndx): Distinquish between pread
210	failing and not having enough data.
211	* elf_begin.c (get_shnum): Likewise. Explicitly set libelf errno on
212	too large value.
213	(file_read_elf): Make sure to always set libelf errno when returning
214	NULL. Distinquish between i/o file and elf data errors.
215
2162017-08-18  Ulf Hermann  <ulf.hermann@qt.io>
217
218	* gelf_xlate.c: Use attribute_packed.
219
2202017-04-27  Ulf Hermann  <ulf.hermann@qt.io>
221
222	* libelfP.h: Use attribute_hidden.
223
2242017-04-27  Ulf Hermann  <ulf.hermann@qt.io>
225
226	* Makefile.am: Use fpic_CFLAGS and dso_LDFLAGS.
227
2282017-08-15  Mark Wielaard  <mark@klomp.org>
229
230	* elf.h: Update from glibc. Add new powerpc note descriptors.
231
2322017-07-19  Gustavo Romero <gromero@linux.vnet.ibm.com>
233
234	* elf.h: Add known type in notes segment descriptor for HTM SPRs.
235
2362017-02-17  Ulf hermann  <ulf.hermann@qt.io>
237
238	* Makefile.am: Add libelf_so_DEPS, which include libeu.a,
239	libelf_so_LIBS.
240	(libelf_so_LDLIBS): Add $(libelf_so_DEPS).
241	(libelf.so$(EXEEXT): Use $(libelf_so_LIBS), require libelf.map
242	from the right directory.
243
2442017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
245
246	* libelfP.h: Don't include config.h.
247
2482017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
249
250	* elf_begin.c: Use F_GETFD rather than F_GETFL.
251
2522017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
253
254	* libelf.h: Define macros for various function attributes and use
255	them.
256
2572017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
258
259	* elf_update.c: Set ELF_F_MMAPPED flag if we mmap from elf_update.
260
2612017-04-19  Mark Wielaard  <mark@klomp.org>
262
263	* elf_getarsym.c (elf_getarsym): Initialize n to zero.
264
2652017-03-27  Mark Wielaard  <mark@klomp.org>
266
267	* elf32_updatefile.c (updatemmap): Always update last_positition.
268	(updatefile): Likewise.
269
2702017-03-24  Mark Wielaard  <mark@klomp.org>
271
272	* elf_compress.c (__libelf_decompress): Check insane compression
273	ratios before trying to allocate output buffer.
274
2752016-10-11  Akihiko Odaki  <akihiko.odaki.4i@stu.hosei.ac.jp>
276	    Mark Wielaard  <mjw@redhat.com>
277
278	* gelf.h (gelf_newehdr): Change return type to void *.
279	(gelf_newphdr): Likewise.
280	* gelf_newehdr.c (gelf_newehdr): Likewise.
281	* gelf_newphdr.c (gelf_newphdr): Likewise.
282
2832016-10-21  Mark Wielaard  <mjw@redhat.com>
284
285	* elf_getdata.c (__libelf_set_rawdata_wrlock): Sanity check
286	offset and size before trying to malloc and read data.
287
2882016-10-26  Mark Wielaard  <mjw@redhat.com>
289
290	* elf_begin.c (read_file): Always set maxsize when parent == NULL.
291
2922016-10-11  Akihiko Odaki  <akihiko.odaki.4i@stu.hosei.ac.jp>
293
294	* elf_getarsym.c (elf_getarsym): Open code rawmemchr when not
295	available.
296	* elf_strptr.c: Include stdbool.h.
297	(validate_str): New function.
298	(elf_strptr): Use validate_str instead of memrchr.
299
3002016-10-11  Akihiko Odaki  <akihiko.odaki.4i@stu.hosei.ac.jp>
301
302	* elf32_updatefile.c: Remove sys/param.h include.
303	* elf32_updatenull.c: Likewise. Add system.h include.
304	* elf_begin.c: Remove sys/param.h.
305	* elf_compress: Likewise. Add system.h include.
306	(MAX): Remove definition.
307
3082016-08-07  Mark Wielaard  <mjw@redhat.com>
309
310	* elf_compress.c (__libelf_reset_rawdata): Check scn->flags and
311	free rawdata_base when malloced. Set ELF_F_MALLOCED for scn->flags.
312	* elf_end.c (elf_end): Check scn->flags and free rawdata_base if
313	malloced.
314	* libelfP.h (struct Elf_Scn): Document flags ELF_F_MALLOCED usage.
315
3162016-07-06  Mark Wielaard  <mjw@redhat.com>
317
318	* elf-knowledge.h (SH_FLAGS_COMBINE): Removed.
319	(SH_FLAGS_IMPORTANT): Likewise.
320
3212016-07-06  Mark Wielaard  <mjw@redhat.com>
322
323	* elf32_updatenull.c (updatenull_wrlock): Ignore e_type when
324	updating phdrs.
325	* elf_getphdrnum.c (__elf_getphdrnum_chk_rdlock): Only do sanity
326	checking if phdrs haven't been read in yet.
327
3282016-06-24  John Ogness  <john.ogness@linutronix.de>
329
330	* elf32_updatenull.c (updatenull_wrlock): Find first section.
331	* elf_nextscn.c (elf_nextscn): When scn is NULL start from 0th
332	section.
333
3342016-06-28  Richard Henderson  <rth@redhat.com>
335
336	* elf.h: Update from glibc.  Add lots of new EM_* definitions.
337
3382016-04-14  Mark Wielaard  <mjw@redhat.com>
339
340	* elf_compress.c (__libelf_compress): Free out_buf if deflateInit
341	fails.
342
3432016-02-13  Mark Wielaard  <mjw@redhat.com>
344
345	* elf32_updatefile.c (updatemmap): Free scns when out of memory.
346
3472016-01-28  Mark Wielaard  <mjw@redhat.com>
348
349	* elf.h: Update from glibc. Add new i386 and x86_64 relocations.
350
3512016-02-12  Mark Wielaard  <mjw@redhat.com>
352
353	* elf.h: Update from glibc. Add NT_ARM_SYSTEM_CALL.
354
3552016-02-04  Mark Wielaard  <mjw@redhat.com>
356
357	* elf_getdata.c (__libelf_set_rawdata_wrlock): Don't adjust align
358	for SHT_NOBITS sections.
359
3602016-01-22  Chih-Hung Hsieh <chh@google.com>
361
362	* elf_compress.c (__libelf_compress): Move nested function
363	'do_deflate_cleanup' to file scope to compile with clang.
364	* elf_strptr.c (elf_strptr): Move nested function 'get_zdata'
365	to file scope to compile with clang.
366
3672016-01-13  Mark Wielaard  <mjw@redhat.com>
368
369	* libelf.h: Check SHF_COMPRESSED is defined. If not define it and the
370	associated ELF compression types/defines.
371
3722015-11-26  Mark Wielaard  <mjw@redhat.com>
373
374	* elf_compress.c (__libelf_decompress_elf): New function, extracted
375	from...
376	(elf_compress): here. Check zdata_base use __libelf_decompress_elf.
377	* elf_strptr.c (elf_strptr): If SHF_COMPRESSED check, uncompress and
378	use zdata.
379	* libelfP.h (struct Elf_Scn): Add zdata_size and zdata_align.
380	(__libelf_decompress_elf): New internal function definition.
381
3822015-10-21  Mark Wielaard  <mjw@redhat.com>
383
384	* Makefile.am (libelf_a_SOURCES): Add elf_compress.c and
385	elf_compress_gnu.c.
386	* elf_compress.c: New file.
387	* elf_compress_gnu.c: Likewise.
388	* elf_begin.c (file_read_elf): Make a writable copy of the shdrs
389	for ELF_C_READ_MMAP.
390	* elf_end.c (elf_end): Free zdata_base.
391	* elf_error.c: Add ELF_E_ALREADY_COMPRESSED,
392	ELF_E_UNKNOWN_COMPRESSION_TYPE, ELF_E_COMPRESS_ERROR and
393	ELF_E_DECOMPRESS_ERROR.
394	* elf_data.c (__libelf_data_type): New internal function extracted
395	from convert_data.
396	(convert_data): Handle SHF_COMPRESSED.
397	* elf32_updatenull.c (updatenull_wrlock): Check sh_entsize against
398	uncompressed section data size if SHF_COMPRESSED.
399	* elf32_getshdr.c (load_shdr_wrlock): Adjust assert to account for
400	ELF_C_READ_MMAP.
401	* libelf.h: Define elf_compress and elf_compress_gnu.
402	* libelf.map (ELFUTILS_1.7): Add elf_compress and elf_compress_gnu.
403	* libelfP.h: Add ELF_E_ALREADY_COMPRESSED,
404	ELF_E_UNKNOWN_COMPRESSION_TYPE, ELF_E_COMPRESS_ERROR and
405	ELF_E_DECOMPRESS_ERROR. Define __libelf_data_type.
406	(__libelf_compress): New internal function definition.
407	(__libelf_decompress): Likewise.
408	(__libelf_reset_rawdata): Likewise.
409	(__libelf_data_type): Likewise.
410	(struct Elf_Scn): Add zdata_base.
411
4122015-11-19  Mark Wielaard  <mjw@redhat.com>
413
414	* Makefile.am (libelf_a_SOURCES): Add elf32_getchdr.c,
415	elf64_getchdr.c and gelf_getchdr.c.
416	(noinst_HEADERS): Add chdr_xlate.h.
417	* abstract.h: Define Chdr32 and Chdr64.
418	* chdr_xlate.h: New file.
419	* elf32_getchdr.c: New file.
420	* elf64_getchdr.c: New file.
421	* elf_error.c: Add ELF_E_NOT_COMPRESSED, ELF_E_INVALID_SECTION_TYPE
422	and ELF_E_INVALID_SECTION_FLAGS.
423	* elf_getdata.c (__libelf_set_rawdata_wrlock): Set d_type to
424	ELF_T_CHDR for SHF_COMPRESSED sections.
425	* exttypes.h: Add Chdr32 and Chdr64.
426	* gelf.h (GElf_Chdr): New typedef.
427	(gelf_getchdr): New function definition.
428	* gelf_fsize.c (__libelf_type_sizes): Add ELF_T_CHDR.
429	* gelf_getchdr.c: New file.
430	* gelf_xlate.c (__elf_xfctstom): Add ELF_T_CHDR cvt_chdr.
431	* gelf_xlate.h: Add Chdr.
432	* libelf.h (Elf_Type): Add ELF_T_CHDR.
433	(elf32_getchdr): New function definition.
434	(elf64_getchdr): Likewise.
435	* libelf.map (ELFUTILS_1.7): New sections add elf32_getchdr,
436	elf64_getchdr and gelf_getchdr.
437	* libelfP.h: Add ELF_E_NOT_COMPRESSED, ELF_E_INVALID_SECTION_TYPE
438	and ELF_E_INVALID_SECTION_FLAGS.
439
4402015-10-16  Mark Wielaard  <mjw@redhat.com>
441
442	* Makefile.am (libelf_so_LDLIBS): Add -lz.
443
4442015-10-14  Mark Wielaard  <mjw@redhat.com>
445
446	* elf.h: Update from glibc. Add section compression constants and
447	structures.
448
4492015-10-20  Jose E. Marchesi  <jose.marchesi@oracle.com>
450
451	* elf_begin.c (get_shnum): Elf64_Shdr.sh_size is an Elf64_Xword.
452	Fix the size argument to pread_retry.
453
4542015-10-13  Chih-Hung Hsieh  <chh@google.com>
455
456	* elf32_updatefile.c (__elfw2(LIBELFBITS,updatemmap)): Move nested
457	function 'fill_mmap' to file scope.
458	* elf_begin.c (elf_begin): Move nested function 'lock_dup_elf'
459	to file scope.
460
4612015-10-09  Josh Stone  <jistone@redhat.com>
462
463	* libelf.h: Replace loff_t with int64_t throughout.
464
4652015-10-05  Mark Wielaard  <mjw@redhat.com>
466
467	* elf_update.c (write_file): Only use posix_fallocate when using
468	mmap. Only report failure when errno is ENOSPC.
469
4702015-10-09  Josh Stone  <jistone@redhat.com>
471
472	* libelfP.h (struct Elf): Replace off64_t with off_t.
473	* elf_getdata_rawchunk.c (elf_getdata_rawchunk): Likewise.
474
4752015-10-05  Chih-Hung Hsieh <chh@google.com>
476
477	* elf_getarsym.c (elf_getarsym): Do not use
478	union of variable length arrays.
479
4802015-10-05  Josh Stone  <jistone@redhat.com>
481
482	* Makefile.am (libelf.so): Add AM_V_CCLD and AM_V_at silencers.
483
4842015-09-24  Jose E. Marchesi  <jose.marchesi@oracle.com>
485
486	* Makefile.am (AM_CFLAGS): Use -fPIC instead of -fpic to avoid
487	relocation overflows in some platforms.
488
4892015-09-29  Mark Wielaard  <mjw@redhat.com>
490
491	* elf32_updatenull.c (default_ehdr): Set e_version when EV_NONE.
492	(updatenull_wrlock): Always set e_shentsize.
493
4942015-09-23  Mark Wielaard  <mjw@redhat.com>
495
496	* elf32_getehdr.c (getehdr_wrlock): Mark as internal_function.
497	* elf32_getshdr.c (getshdr_rdlock): Likewise.
498	(getshdr_wrlock): Likewise.
499	* elf_error.c (__libelf_seterrno): Likewise.
500	* elf_getphdrnum.c (__elf_getphdrnum_rdlock): Likewise.
501	(__elf_getphdrnum_chk_rdlock): Likewise.
502	* elf_getshdrnum.c (__elf_getphdrnum_rdlock): Likewise.
503	(__elf_getphdrnum_chk_rdlock): Likewise.
504	* elf_getshdrnum.c (__elf_getshdrnum_rdlock): Likewise.
505	* elf_readall.c (__libelf_readall): Likewise.
506	* gelf_getehdr.c (__gelf_getehdr_rdlock): Likewise.
507
5082015-09-22  Mark Wielaard  <mjw@redhat.com>
509
510	* *.c: Remove old-style function definitions.
511
5122015-06-22  Mark Wielaard  <mjw@redhat.com>
513
514	* dl-hash.h: Update from glibc.
515
5162015-06-18  Mark Wielaard  <mjw@redhat.com>
517
518	* elf32_updatefile.c (updatefile): Always free shdr_data and scns
519	when allocated on failure paths.
520
5212015-06-18  Mark Wielaard  <mjw@redhat.com>
522
523	* nlist.c (nlist): Check symscn shdr exists before use.
524
5252015-06-16  Mark Wielaard  <mjw@redhat.com>
526
527	* elf_update.c (write_file): Always also use ftruncate before
528	posix_fallocate to make sure file has the right size.
529
5302015-06-04  Mark Wielaard  <mjw@redhat.com>
531
532	* elf_getdata.c (__libelf_type_aligns): Add entries for ELF_T_EHDR,
533	ELF_T_OFF, ELF_T_PHDR, ELF_T_SHDR, ELF_T_SWORD, ELF_T_XWORD,
534	ELF_T_SXWORD, ELF_T_GNUHASH, ELF_T_AUXV.
535	* elf_getdata_rawchunk.c (elf_getdata_rawchunk): Check alignment
536	of rawdata against requested type.
537
5382015-06-02  Mark Wielaard  <mjw@redhat.com>
539
540	* elf_getdata.c (convert_data): Make sure source data is properly
541	aligned for type before calling actual conversion function.
542
5432015-06-04  Mark Wielaard  <mjw@redhat.com>
544
545	* elf_begin.c (get_shnum): Check alignment of Shdr, not Ehdr before
546	direct access.
547
5482015-06-02  Mark Wielaard  <mjw@redhat.com>
549
550	* elf_begin.c (file_read_elf): Split checks for ehdr and shdr
551	alignment, drop phdr alignment check.
552
5532015-05-31  Mark Wielaard  <mjw@redhat.com>
554
555	* elf32_getshdr.c (load_shdr_wrlock): Allocate shdrs with malloc,
556	not alloca and free after conversion when a copy needs to be made.
557
5582015-05-31  Mark Wielaard  <mjw@redhat.com>
559
560	* elf32_getphdr.c (getphdr_wrlock): Allocate phdrs with malloc, not
561	alloca and free after conversion when a copy needs to be made.
562
5632015-05-31  Mark Wielaard  <mjw@redhat.com>
564
565	* elf_getarsym.c (elf_getarsym): Allocate temporary file_date with
566	malloc, not alloca also in !ALLOW_UNALIGNED case.
567
5682015-05-30  Mark Wielaard  <mjw@redhat.com>
569
570	* gelf_xlate.c (elf_cvt_Byte): Only call memmove with non-zero size.
571
5722015-05-30  Mark Wielaard  <mjw@redhat.com>
573
574	* elf32_updatefile.c (updatemmap): Only call mempcpy and update
575	last_position when d_size is non-zero.
576
5772015-05-17  Mark Wielaard  <mjw@redhat.com>
578
579	* elf32_updatefile.c (updatefile): Allocate shdr_data and scns
580	with malloc, not alloca. Free after writing section headers.
581
5822015-05-16  Mark Wielaard  <mjw@redhat.com>
583
584	* elf32_updatefile.c (updatemmap): Allocate temporary shdr storage
585	with malloc, not alloca. Free after writing section header.
586
5872015-05-16  Mark Wielaard  <mjw@redhat.com>
588
589	* elf_getarsym.c (elf_getarsym): Allocate temporary file_date with
590	malloc, not alloca. Call free after out.
591
5922015-05-14  Mark Wielaard  <mjw@redhat.com>
593
594	* elf_update.c (write_file): Use posix_fallocate instead of
595	ftruncate to extend file if necessary.
596
5972015-05-13  Mark Wielaard  <mjw@redhat.com>
598
599	* elf32_updatenull.c (default_ehdr): If e_phnum is zero then set
600	e_phoff also to zero.
601
6022015-05-12  Mark Wielaard  <mjw@redhat.com>
603
604	* elf32_updatenull.c (updatenull_wrlock): Check that sh_addralign
605	is a powerof2.
606	* elf_getdata.c (__libelf_set_rawdata_wrlock): Clamp large d_aligns
607	to the elf image offset.
608
6092015-05-12  Mark Wielaard  <mjw@redhat.com>
610
611	* elf32_newphdr.c (newphdr): Call __libelf_seterrno with
612	ELF_E_INVALID_INDEX before failing. Check whether section zero shdr
613	actually exists if we need to put extended phnum in section zero.
614
6152015-05-08  Mark Wielaard  <mjw@redhat.com>
616
617	* nlist.c (nlist): Call gelf_fsize with EV_CURRENT.
618
6192015-01-03  Mark Wielaard  <mjw@redhat.com>
620
621	* version_xlate.h (elf_cvt_Verdef): Use memmove to copy src to dest.
622	(elf_cvt_Verneed): Likewise.
623
6242015-03-28  Mark Wielaard  <mjw@redhat.com>
625
626	* elf.h: Update from glibc.
627
6282015-03-23  Mark Wielaard  <mjw@redhat.com>
629
630	* elf32_updatenull.c (updatenull_wrlock): Don't extend size with
631	SHT_NOBITS sh_offset.
632
6332015-02-18  Mark Wielaard  <mjw@redhat.com>
634
635	* libelfP.h (__libelf_set_data_list_rdlock): Make internal_function.
636
6372015-02-07  Jan Kratochvil  <jan.kratochvil@redhat.com>
638
639	* elf32_updatenull.c (__elfw2(LIBELFBITS,updatenull_wrlock)): Consider
640	sh_addralign 0 as 1.
641
6422015-01-22  Mark Wielaard  <mjw@redhat.com>
643
644	* elf_strptr (elf_strptr): Make sure returned string is NUL
645	terminated.
646
6472015-01-21  Mark Wielaard  <mjw@redhat.com>
648
649	* elf_strptr.c (elf_strptr): Check data_list_rear == NULL instead
650	of rawdata_base != NULL before using rawdata directly.
651
6522015-01-20  Mark Wielaard  <mjw@redhat.com>
653
654	* libelfP.h (__elf_strptr_internal): New function declaration.
655	* elf_getdata.c (__libelf_set_data_list_rdlock): New internal
656	function extracted from...
657	(__elf_getdata_rdlock): ... here.
658	* elf_newdata.c (elf_newdata): Check scn->rawdata_base and update
659	datalist if necessary.
660
6612015-01-20  Mark Wielaard  <mjw@redhat.com>
662
663	* elf_strptr.c (elf_strptr): Call __elf[32|64]_getshdr_rdlock if
664	necessary.
665
6662014-12-30  Mark Wielaard  <mjw@redhat.com>
667
668	* elf_getphdrnum.c (__elf_getphdrnum_chk_rdlock): New function.
669	(elf_getphdrnum): Call __elf_getphdrnum_chk_rdlock.
670	* gelf_getphdr (gelf_getphdr): Call __elf_getphdrnum_chk_rdlock
671	and always check ndx against phnum.
672	* libelfP.h (__elf_getphdrnum_chk_rdlock): New internal function.
673
6742014-12-25  Mark Wielaard  <mjw@redhat.com>
675
676	* elf_begin.c (__libelf_next_arhdr_wrlock): ar_size cannot be
677	negative. Include start_offset in maxsize.
678
6792014-12-28  Alexander Cherepanov  <cherepan@mccme.ru>
680
681	* elf_begin.c (read_long_names): Don't miss '/' right after
682	another '/'. Fixes a dir traversal vuln in ar extraction.
683
6842014-12-18  Ulrich Drepper  <drepper@gmail.com>
685
686	* Makefile.am: Suppress output of textrel_check command.
687
6882014-12-16  Mark Wielaard  <mjw@redhat.com>
689
690	* elf_begin.c (read_long_names): Make sure long_names len fits
691	in mapped ELF file.
692
6932014-12-15  Mark Wielaard  <mjw@redhat.com>
694
695	* elf_getarsym.c (elf_getarsym): Check index_size doesn't overflow.
696
6972014-12-15  Mark Wielaard  <mjw@redhat.com>
698
699	* elf_begin.c (read_long_names): Clear any garbage left in the
700	name table.
701
7022014-12-11  Mark Wielaard  <mjw@redhat.com>
703
704	* elf_begin.c (file_read_elf): Correct ELF64 section offset check.
705
7062014-12-11  Mark Wielaard  <mjw@redhat.com>
707
708	* elf_begin.c (read_long_names): Check for offset overflow.
709	(__libelf_next_arhdr_wrlock): Likewise. Sanity check the ar_size.
710	Don't allow it to go beyond end of file.
711
7122014-12-09  Mark Wielaard  <mjw@redhat.com>
713
714	* elf_getarsym.c (elf_getarsym): Make sure n * w doesn't overflow.
715
7162014-11-27  Mark Wielaard  <mjw@redhat.com>
717
718	* Makefile.am (libelf.so): Use textrel_check.
719
7202014-11-23  Mark Wielaard  <mjw@redhat.com>
721
722	* elf_getdata_rawchunk.c (elf_getdata_rawchunk): Change signed
723	overflow check to unsigned.
724
7252014-11-23  Mark Wielaard  <mjw@redhat.com>
726
727	* note_xlate.h (elf_cvt_note): Copy over any leftover data if
728	src != dest. The data is probably part of truncated name/desc.
729
7302014-11-22  Mark Wielaard  <mjw@redhat.com>
731
732	* elf_getphdrnum.c (elf_getphdrnum): Sanity check the
733	__elf_getphdrnum_rdlock result.
734
7352014-11-18  Mark Wielaard  <mjw@redhat.com>
736
737	* version_xlate.h (elf_cvt_Verdef): Check for overflow.
738	(elf_cvt_Verneed): Likewise.
739
7402014-11-17  Mark Wielaard  <mjw@redhat.com>
741
742	* elf-knowledge.h (SECTION_STRIP_P): Check name is not NULL.
743
7442014-11-16  Mark Wielaard  <mjw@redhat.com>
745
746	* elf_getshdrstrndx.c: Check there are section headers before
747	handling SHN_XINDEX.
748
7492014-11-16  Mark Wielaard  <mjw@redhat.com>
750
751	* elf32_getphdr.c (getphdr_wrlock): Check e_phoff isn't zero.
752	Check for too many pheaders.
753	* elf_getphdrnum.c (__elf_getphdrnum_rdlock): Check section zero
754	actually exists before handling PN_XNUM.
755
7562014-11-16  Mark Wielaard  <mjw@redhat.com>
757
758	* gelf_getnote.c (gelf_getnote): Check padding overflow.
759
7602014-11-16  Mark Wielaard  <mjw@redhat.com>
761
762	* elf_getdata.c (__libelf_set_rawdata_wrlock): Declare offset, size
763	and align as Elf64_Off and Elf64_Xword not size_t.
764
7652014-11-14  Mark Wielaard  <mjw@redhat.com>
766
767	* gelf_getnote.c (gelf_getnote): Check offset overflow.
768
7692014-11-13  Mark Wielaard  <mjw@redhat.com>
770
771	* elf_getdata.c (__libelf_set_rawdata_wrlock): Fix unsigned overflow
772	check.
773
7742014-11-08  Mark Wielaard  <mjw@redhat.com>
775
776	* elf_begin.c (__libelf_next_arhdr_wrlock): Use mempcpy not __mempcpy.
777
7782014-11-07  Mark Wielaard  <mjw@redhat.com>
779
780	* elf_begin.c (file_read_elf): Correct sh_size check.
781	* elf_getdata.c (__libelf_set_rawdata_wrlock): Check for unsigned
782	overflow.
783
7842014-09-10  Petr Machata  <pmachata@redhat.com>
785
786	* elf_begin (read_unmmaped_file): Call __libelf_seterrno if the
787	file is unreadable.
788
7892014-07-07  Mark Wielaard  <mjw@redhat.com>
790
791	* elf.h: Update from glibc.
792
7932014-04-13  Mark Wielaard  <mjw@redhat.com>
794
795	* Makefile.am: Remove !MUDFLAP conditions.
796	* elf_begin.c (read_file): Don't clear use_mmap when _MUDFLAP is
797	defined.
798	* elf_update.c (write_file): Remove _MUDFLAP condition.
799
8002014-01-17  Jakub Jelinek  <jakub@redhat.com>
801	    Roland McGrath  <roland@redhat.com>
802
803	* libelfP.h (INVALID_NDX): Define.
804	* gelf_getdyn.c (gelf_getdyn): Use it.  Remove ndx < 0 test if any.
805	* gelf_getlib.c (gelf_getlib): Likewise.
806	* gelf_getmove.c (gelf_getmove): Likewise.
807	* gelf_getrel.c (gelf_getrel): Likewise.
808	* gelf_getrela.c (gelf_getrela): Likewise.
809	* gelf_getsym.c (gelf_getsym): Likewise.
810	* gelf_getsyminfo.c (gelf_getsyminfo): Likewise.
811	* gelf_getsymshndx.c (gelf_getsymshndx): Likewise.
812	* gelf_getversym.c (gelf_getversym): Likewise.
813	* gelf_update_dyn.c (gelf_update_dyn): Likewise.
814	* gelf_update_lib.c (gelf_update_lib): Likewise.
815	* gelf_update_move.c (gelf_update_move): Likewise.
816	* gelf_update_rel.c (gelf_update_rel): Likewise.
817	* gelf_update_rela.c (gelf_update_rela): Likewise.
818	* gelf_update_sym.c (gelf_update_sym): Likewise.
819	* gelf_update_syminfo.c (gelf_update_syminfo): Likewise.
820	* gelf_update_symshndx.c (gelf_update_symshndx): Likewise.
821	* gelf_update_versym.c (gelf_update_versym): Likewise.
822
8232014-01-17  Jakub Jelinek  <jakub@redhat.com>
824
825	* elf32_getphdr.c (elfw2(LIBELFBITS,getphdr)): Check if program header
826	table fits into object's bounds.
827	* elf_getshdrstrndx.c (elf_getshstrndx): Add elf->start_offset to
828	elf->map_address.  Check if first section header fits into object's
829	bounds.
830	* elf32_getshdr.c (elfw2(LIBELFBITS,getshdr)):
831	Check if section header table fits into object's bounds.
832	* elf_begin.c (get_shnum): Ensure section headers fits into
833	object's bounds.
834	(file_read_elf): Make sure scncnt is small enough to allocate both
835	ElfXX_Shdr and Elf_Scn array.  Make sure section and program header
836	tables fit into object's bounds.  Avoid memory leak on failure.
837	* elf_newscn.c (elf_newscn): Check for overflow.
838	* elf32_updatefile.c (__elfw2(LIBELFBITS,updatemmap)): Likewise.
839	(__elfw2(LIBELFBITS,updatefile)): Likewise.
840	* elf32_newphdr.c (elfw2(LIBELFBITS,newphdr)): Likewise.
841	* elf_getarsym.c (elf_getarsym): Likewise.
842
8432013-11-08  Mark Wielaard  <mjw@redhat.com>
844
845	* elf32_updatefile.c (elfXX_updatemmap): Only memcpy ehdr when not
846	already directly mmapped.
847
8482013-11-05  Mark Wielaard  <mjw@redhat.com>
849
850	* elf32_updatefile.c (elfXX_updatefile): Copy all section headers
851	if elf->flags dirty.
852
8532013-11-01  Michael Forney  <mforney@mforney.org>
854
855	* Makefile.am: Use READELF.
856
8572013-10-01  Petr Machata  <pmachata@redhat.com>
858
859	* elf.h: Update from glibc.
860
8612013-06-17  Petr Machata  <pmachata@redhat.com>
862
863	* elf.h: Update from glibc.
864
8652013-08-28  Namhyung Kim  <namhyung@gmail.com>
866
867	* gelf.h (gelf_fsize): Fix typo in comment.
868
8692013-08-28  Mark Wielaard  <mjw@redhat.com>
870
871	* gelf_getauxv.c (gelf_getauxv): Add missing whitespace.
872
8732013-08-27  Mark Wielaard  <mjw@redhat.com>
874
875	* gelf_getauxv.c (gelf_getauxv): Remove unnecessary casts to char *.
876
8772013-08-25  Kurt Roeckx  <kurt@roeckx.be>
878
879	* gelf_getauxv.c (gelf_getauxv): Use memcpy instead of pointer
880	dereference to avoid alignment problems.
881
8822013-01-07  Roland McGrath  <roland@hack.frob.com>
883
884	* elf_getarsym.c (elf_getarsym): Copy FILE_DATA into stack space if it
885	would be unaligned and !ALLOW_UNALIGNED.
886
887	* elf_getarsym.c (read_number_entries): Use memcpy instead of pointer
888	dereference so as not to assume the field is naturally aligned.
889
8902012-09-17  Petr Machata  <pmachata@redhat.com>
891
892	* elf.h: Update from glibc.
893
8942012-08-16  Roland McGrath  <roland@hack.frob.com>
895
896	* elf.h: Update from glibc.
897
8982012-08-14  Mark Wielaard  <mjw@redhat.com>
899
900	* elf32_checksum.c (ebl_debugscn_p): Removed unused define and
901	confusing outdated comment.
902
9032012-08-01  Petr Machata  <pmachata@redhat.com>
904
905	* elf_getarsym (read_number_entries): New function.
906	(elf_getarsym): Handle 64-bit symbol table, stored in special
907	entry named "/SYM64/".
908	* elf_begin.c (__libelf_next_arhdr_wrlock): Don't reject archive
909	because it contains 64-bit symbol table.
910
9112012-07-19  Mark Wielaard  <mjw@redhat.com>
912
913	* elf32_getshdr.c (load_shdr_wrlock): Add elf->flags & ELF_F_MALLOCED
914	to asserts.
915
9162012-07-17  Petr Machata  <pmachata@redhat.com>
917
918	* elf32_xlatetom.c (elfw2(LIBELFBITS, xlatetom)): Do not check for
919	integer number of records in case of ELF_T_NHDR.
920
9212012-04-02  Mark Wielaard  <mjw@redhat.com>
922
923	* elf32_offscn.c: Do not match SHT_NOBITS sections at OFFSET unless
924	there are no nonempty sections at that offset.
925
9262012-03-21  Roland McGrath  <roland@hack.frob.com>
927
928	* elf-knowledge.h (SECTION_STRIP_P): Remove < SHT_NUM check.
929
9302011-02-26  Mark Wielaard  <mjw@redhat.com>
931
932	* elf_end.c (elf_end): Call rwlock_unlock before rwlock_fini.
933
9342011-01-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
935
936	* elf_getdata_rawchunk.c (elf_getdata_rawchunk): Fix off64_t overflow
937	when MAXIMUM_SIZE == ~0.
938
9392010-08-18  Roland McGrath  <roland@redhat.com>
940
941	* gelf_fsize.c (__libelf_type_sizes): Add entries for ELF_T_LIB
942	and ELF_T_GNUHASH.
943	Reported by Mark Hatle <mark.hatle@windriver.com>.
944
945	* exttypes.h: Add cases for ElfNN_Lib.
946	Reported by Mark Hatle <mark.hatle@windriver.com>.
947
9482010-06-14  Ulrich Drepper  <drepper@redhat.com>
949
950	* gelf_update_shdr.c: Implicitly set ELF_F_DIRTY bit.
951	* gelf_update_phdr.c: Likewise.
952	* gelf_update_ehdr.c: Likewise.
953
9542010-04-14  Roland McGrath  <roland@redhat.com>
955
956	* elf32_getphdr.c: Check for e_phoff/size outside the file bounds.
957	* elf_begin.c (file_read_elf): Don't set .phdr here.
958
9592010-04-13  Roland McGrath  <roland@redhat.com>
960
961	* elf.h: Update from glibc.
962
9632010-04-06  Roland McGrath  <roland@redhat.com>
964
965	* elf_error.c (ELF_E_FD_MISMATCH_IDX): Avoid nonobvious abbreviation
966	in error message.
967
9682010-04-01  Petr Machata  <pmachata@redhat.com>
969
970	* elf_getdata.c (__elf_getdata_rdlock): Initialize data.s for data
971	that do not need a conversion.
972
9732010-03-11  Roland McGrath  <roland@redhat.com>
974
975	* elf.h: Update from glibc.
976
9772010-03-04  Ulrich Drepper  <drepper@redhat.com>
978
979	* elf.h: Update from glibc.
980
9812010-02-17  Roland McGrath  <roland@redhat.com>
982
983	* elf_begin.c (file_read_elf): Leave section rawdata_base and
984	data_base pointers null when [sh_offset,sh_size) points outside
985	the mapped file.
986
9872010-02-15  Roland McGrath  <roland@redhat.com>
988
989	* Makefile.am: Use config/eu.am for common stuff.
990
9912010-01-07  Roland McGrath  <roland@redhat.com>
992
993	* elf32_getphdr.c: Use __elf_getphdrnum_rdlock.
994	* gelf_getphdr.c: Likewise.
995	* gelf_update_phdr.c: Likewise.
996	* elf32_updatefile.c (__elf32_updatemmap, __elf32_updatefile): Likewise.
997	* elf32_updatenull.c (__elf32_updatenull_wrlock): Likewise.
998	* elf32_newphdr.c: Clear section 0's sh_info when resetting e_phnum.
999	If COUNT is too large, use store PN_XNUM instead and set sh_info.
1000	* elf_begin.c (file_read_elf): Always allocate space we can use later
1001	for section 0 if doing RDWR.
1002
1003	* elf_getphdrnum.c: New file.
1004	* Makefile.am (libelf_a_SOURCES): Add it.
1005	* libelf.h: Declare elf_getphdrnum.
1006	* libelfP.h: Declare __elf_getphdrnum_rdlock.
1007	* libelf.map (ELFUTILS_1.6): New set, add elf_getphdrnum.
1008
1009	* elf.h: Update from glibc.
1010
10112009-10-23  Lubomir Rintel  <lkundrak@v3.sk>
1012
1013	* elf32_updatefile.c (fill_mmap): When starting past shdr_end, start
1014	filling from section start, not shdr_end.
1015
10162009-11-10  Roland McGrath  <roland@redhat.com>
1017
1018	* elf_readall.c (__libelf_readall): Fetch file size if not yet known.
1019
10202009-11-06  Mark Wielaard  <mjw@redhat.com>
1021
1022	* elf_next.c (elf_next): Mark the archive header as unusable when
1023	there is no next ar element.
1024
10252009-08-12  Mark Wielaard  <mjw@redhat.com>
1026
1027	* Makefile.am (libelf.so): Use -Wl,-z,defs not -defs.
1028
10292009-07-26  Ulrich Drepper  <drepper@redhat.com>
1030
1031	* elf.h: Update from glibc.
1032
10332009-07-21  Ulrich Drepper  <drepper@redhat.com>
1034
1035	* elf32_updatefile.c (__elfXX_updatemmap): Fix handling of gaps between
1036	sections.  Patch by Lubomir Rintel <lkundrak@v3.sk>.
1037
10382009-07-08  Roland McGrath  <roland@redhat.com>
1039
1040	* libelfP.h (struct Elf): Remove unused ar.has_index field.
1041	Reorder various members for optimal packing.
1042
10432009-07-08  Ulrich Drepper  <drepper@redhat.com>
1044
1045	* elf.h: Update from glibc.
1046
10472009-06-13  Ulrich Drepper  <drepper@redhat.com>
1048
1049	* Makefile.am (libelf_a_SOURCES): Replace elf_getshnum.c and
1050	elf_getshstrndx.c with elf_getshdrnum.c and elf_getshdrstrndx.c.
1051	* elf_getshnum.c: Renamed to...
1052	* elf_getshdrnum.c: ...this.  Rename function and add old name as
1053	alias.  Likewise for internal functions with derived names.
1054	* elf_getshstrndx.c: Renamed to...
1055	* elf_getshdrstrndx.c: ...this.  Rename function and add old name as
1056	alias.  Likewise for internal functions with derived names.
1057	* libelf.h: Add prototypes for new names.  Make old names as
1058	deprecated.
1059	* libelfP.h: Rename internal function prototypes.
1060	* libelf.map: Export for names.
1061	* elf32_checksum.c: Don't use deprecated functions.
1062	* elf32_getshdr.c: Likewise.
1063
10642009-06-01  Ulrich Drepper  <drepper@redhat.com>
1065
1066	* elf.h: Update from glibc.
1067
10682009-04-14  Roland McGrath  <roland@redhat.com>
1069
1070	* elf.h: Update from glibc.
1071
10722009-04-01  Roland McGrath  <roland@redhat.com>
1073
1074	* elf.h: Update from glibc.
1075
10762009-02-10  Ulrich Drepper  <drepper@redhat.com>
1077
1078	* elf32_updatefile.c (updatefile): For the zeroth section we still
1079	have to copy the section header.
1080
10812009-02-01  Ulrich Drepper  <drepper@redhat.com>
1082
1083	* elf_strptr.c: Add comment re possible problem.
1084
10852009-01-26  Ulrich Drepper  <drepper@redhat.com>
1086
1087	* elf32_updatenull.c (updatenull_wrlock): Fix comment of
1088	ELF_F_LAYOUT behaviour re section header table.
1089
10902009-01-22  Ulrich Drepper  <drepper@redhat.com>
1091
1092	* elf32_updatefile.c (__elfXX_updatemmap): Fill the gap between
1093	sections even if only the section at the start of the gap has been
1094	changed.
1095	(__elfXX_updatefile): Likewise.
1096
10972009-01-21  Ulrich Drepper  <drepper@redhat.com>
1098
1099	* elf32_updatefile.c (__elfXX_updatemmap): Skip most of the loop to
1100	handle sections for NOBITS sections.
1101	(elfXX_updatefile): Likewise.
1102
1103	* elf32_updatefile.c (__elfXX_updatemmap): When skipping non-NOBITS
1104	sections we haven't loaded, update last_position based on scn_start,
1105	not based on old value.  Don't run the loop for the dummy section 0.
1106	(elfXX_updatefile): Don't run the loop for the dummy section 0.
1107
11082009-01-10  Ulrich Drepper  <drepper@redhat.com>
1109
1110	* libelfP.h (_): We only have one translation domain, elfutils.
1111
1112	* Makefile.am: Use USE_LOCKS instead of USE_TLS.
1113	* elf_error.c: Always use __thread.  Remove all !USE_TLS code.
1114
11152009-01-04  Roland McGrath  <roland@redhat.com>
1116
1117	* note_xlate.h (elf_cvt_note): Don't examine a size too small to
1118	container a note header.
1119
11202008-12-11  Roland McGrath  <roland@redhat.com>
1121
1122	* elf32_updatefile.c (__elfw2(LIBELFBITS,updatemmap)): Handle
1123	placement offset going backwards, for out-of-order or overlapping
1124	(bogus) sh_offset layouts.  It's a dumb use, but should not crash.
1125	(__elfw2(LIBELFBITS,updatefile)): Likewise.
1126	Fixes RHBZ#476136.
1127
1128	* libelf.h (Elf_Data): Whitespace fix.
1129
11302008-12-10  Roland McGrath  <roland@redhat.com>
1131
1132	* elf_getarhdr.c (elf_getarhdr): Fix missing rename in last change.
1133
11342008-10-22  Petr Machata  <pmachata@redhat.com>
1135
1136	* elf_rawfile.c (elf_rawfile): Lock around elf-> references.
1137
11382008-10-21  Petr Machata  <pmachata@redhat.com>
1139
1140	* libelfP.h: Rename getehdr_rdlock to getehdr_wrlock.
1141	* elf32_getehdr.c (getehdr_rdlock): Move the code to new function
1142	getehdr_impl and make it a wrapper.  Rename to getehdr_wrlock.
1143	(getehdr_impl): Guard elf->class init with wrlock.
1144	(getehdr): Also make it a wrapper of getehdr_impl.
1145	* elf32_updatenull.c (updatenull_wrlock): Call getehdr_wrlock.
1146
11472008-10-20  Petr Machata  <pmachata@redhat.com>
1148
1149	* elf_getdata_rawchunk.c (elf_getdata_rawchunk): Lock around the
1150	code that reads mutable elf state.  Relock to write lock to chain
1151	the new chunk on the elf rawchunks list.
1152
11532008-10-20  Petr Machata  <pmachata@redhat.com>
1154
1155	* elf32_checksum.c (checksum): Place a lock around the code that
1156	processes data.  Make it wrlock if the code needs to xlate the
1157	data before processing.
1158
11592008-10-16  Petr Machata  <pmachata@redhat.com>
1160
1161	* elf_begin.c
1162	(__libelf_next_arhdr): Rename to __libelf_next_arhdr_wrlock.
1163	(dup_elf): Adjust the call.
1164	(elf_begin): New local function lock_dup_elf.  Relocks the elf if
1165	necessary before calling dup.  Call this instead of dup_elf.
1166	* elf_getarhdr.c
1167	(elf_getarhdr): Lock before calling __libelf_next_arhdr_wrlock.
1168	* elf_next.c (elf_next): Likewise.
1169	* elf_rand.c (elf_rand): Likewise.
1170
11712008-10-14  Petr Machata  <pmachata@redhat.com>
1172
1173	* elf_getdata.c (__elf_getdata_rdlock): Lock before converting.
1174
11752008-11-26  Roland McGrath  <roland@redhat.com>
1176
1177	* elf.h: Update from glibc.
1178
11792008-10-06  Roland McGrath  <roland@redhat.com>
1180
1181	* elf_getarhdr.c (elf_getarhdr): Return NULL when passed NULL.
1182
11832008-08-27  Roland McGrath  <roland@redhat.com>
1184
1185	* elf_begin.c (get_shnum): Avoid misaligned reads for matching endian.
1186
1187	* libelfP.h [!ALLOW_UNALIGNED] (__libelf_type_align): Fix CLASS index.
1188
11892008-08-25  Roland McGrath  <roland@redhat.com>
1190
1191	* Makefile.am (libelf_so_LDLIBS): New variable.
1192	(libelf.so): Use it in the link.
1193
11942008-08-21  Petr Machata  <pmachata@redhat.com>
1195
1196	* elf_getdata.c, libelfP.h
1197	(__elf_getdata_internal): Rename to __elf_getdata_rdlock.
1198	(__libelf_set_rawdata_wrlock): New function.
1199	(__libelf_set_rawdata): Make it a wrapper that calls *_wrlock.
1200	* elf32_updatenull.c, libelfP.h
1201	(__elfNN_updatenull): Rename to __elfNN_updatenull_wrlock.
1202
12032008-08-21  Petr Machata  <pmachata@redhat.com>
1204
1205	* elf32_getphdr.c, libelfP.h
1206	(__elfNN_getphdr_internal): Drop.  Move __elfNN_getphdr_internal
1207	code to __elfNN_getphdr_wrlock.
1208	(__elfNN_getphdr_rdlock, __elfNN_getphdr_wrlock): New functions.
1209	(__elfNN_getphdr_rdlock, __elfNN_getphdr_wrlock): Make these
1210	wrappers of getphdr_impl.
1211
12122008-08-21  Petr Machata  <pmachata@redhat.com>
1213
1214	* elf32_getehdr.c, libelfP.h
1215	(__elfNN_getehdr_internal): Rename to __elfNN_getehdr_rdlock.
1216	* gelf_getehdr, libelfP.h:
1217	(__gelf_getehdr_internal): Rename to __gelf_getehdr_rdlock.
1218
12192008-08-21  Petr Machata  <pmachata@redhat.com>
1220
1221	* elf32_getshdr.c
1222	(__elfNN_getshdr_internal): Drop.
1223	(load_shdr_wrlock, scn_valid): New functions, contain bits of
1224	behaviour from __elfNN_getshdr_internal.
1225	(__elfNN_getshdr_rdlock, __elfNN_getshdr_wrlock): Replacements for
1226	dropped _internal functions above.
1227	* elf_getshnum.c
1228	(__elf_getshnum_internal): Rename to __elf_getshnum_rdlock.
1229
12302008-08-04  Petr Machata  <pmachata@redhat.com>
1231
1232	* libelfP.h (RWLOCK_RDLOCK, RWLOCK_WRLOCK, RWLOCK_UNLOCK): New macros.
1233
12342008-07-28  Roland McGrath  <roland@redhat.com>
1235
1236	* elf.h: Update from glibc.
1237
12382008-03-31  Roland McGrath  <roland@redhat.com>
1239
1240	* elf32_offscn.c: Make sure shdrs have been read in.
1241
12422008-02-19  Roland McGrath  <roland@redhat.com>
1243
1244	* elf.h: Update from glibc.
1245
12462008-02-08  Roland McGrath  <roland@redhat.com>
1247
1248	* elf.h: Update from glibc.
1249
12502008-01-31  Ulrich Drepper  <drepper@redhat.com>
1251
1252	* elf_strptr.c (elf_strptr): Don't fail if the ELF file is currently
1253	under construction and no raw data can be read from disk.
1254
12552008-01-30  Roland McGrath  <roland@redhat.com>
1256
1257	* elf.h: Update from glibc.
1258
12592008-01-26  Roland McGrath  <roland@redhat.com>
1260
1261	* elf_begin.c (__libelf_next_arhdr): Rewrite conversions using a macro.
1262	Fixes various pastos in wrong type in sizeof, wrong string parsed.
1263
12642008-01-20  Roland McGrath  <roland@redhat.com>
1265
1266	* elf_getaroff.c: Calculate from start_offset, instead of using
1267	parent's state.ar.offset field.
1268
12692008-01-08  Roland McGrath  <roland@redhat.com>
1270
1271	* Makefile.am (euinclude): Variable removed.
1272	(pkginclude_HEADERS): Set this instead of euinclude_HEADERS.
1273
12742008-01-03  Roland McGrath  <roland@redhat.com>
1275
1276	* common.h: Add __attribute__ ((unused)) to static functions.
1277
12782007-12-20  Ulrich Drepper  <drepper@redhat.com>
1279
1280	* Makefile.am (libelf_a_SOURCES): Add elf_scnshndx.
1281	* libelfP.h (struct Elf_Scn): Add shndx_index field.
1282	Declare __elf_scnshndx_internal.
1283	* elf32_getshdr.c: Record location of extended section header.
1284	* elf_begin.c (file_read_elf): Likewise.
1285	* elf_scnshndx.c: New file.
1286	* libelf.h: Declare elf_scnshndx.
1287	* libelf.map: Add elf_scnshndx to version ELFUTILS_1.4.
1288
12892007-11-12  Roland McGrath  <roland@redhat.com>
1290
1291	* libelf.h: Replace off64_t with loff_t throughout.
1292	Only that type name is unconditionally defined by <sys/types.h>
1293
12942007-11-03  Roland McGrath  <roland@redhat.com>
1295
1296	* libelf.h (Elf_Data): Comment fix.
1297
12982007-10-18  Roland McGrath  <roland@redhat.com>
1299
1300	* elf.h: Update from glibc.
1301
13022007-10-07  Roland McGrath  <roland@redhat.com>
1303
1304	* elf_begin.c (__libelf_next_arhdr): Fix fencepost error and wrong
1305	member access in terminating name with no trailing /.  Trim trailing
1306	spaces when there is no /.
1307
13082007-10-04  Roland McGrath  <roland@redhat.com>
1309
1310	* elf_end.c (elf_end): Don't free ELF->state.ar.ar_sym when it's -1l.
1311
13122007-10-03  Roland McGrath  <roland@redhat.com>
1313
1314	* libelf.h (Elf_Data): Use off64_t for d_off.
1315	(Elf_Arhdr): Use off64_t for ar_size.
1316	(elf_update, elf_getbase, elf_getaroff): Return off64_t.
1317
1318	* gelf_rawchunk.c: File removed.
1319	* gelf_freechunk.c: File removed.
1320	* Makefile.am (libelf_a_SOURCES): Remove them.
1321	* libelf.map (ELFUTILS_1.0): Remove exports.
1322	* gelf.h: Remove decls.
1323
1324	* elf_getdata_rawchunk.c: New file.
1325	* Makefile.am (libelf_a_SOURCES): Add it.
1326	* libelf.map (ELFUTILS_1.3): Add elf_getdata_rawchunk.
1327	* libelf.h: Declare it.
1328	* libelfP.h (Elf_Data_Chunk): New type.
1329	(struct Elf.elf): New member `rawchunks'.
1330	* elf_end.c (elf_end): Free recorded rawchunk buffers.
1331
13322007-08-24  Roland McGrath  <roland@redhat.com>
1333
1334	* gelf_getnote.c: New file.
1335	* Makefile.am (libelf_a_SOURCES): Add it.
1336	* gelf.h: Declare gelf_getnote.
1337	* libelf.map (ELFUTILS_1.3): Add gelf_getnote.
1338
1339	* libelfP.h (NOTE_ALIGN): New macro.
1340	* note_xlate.h: New file.
1341	* Makefile.am (noinst_HEADERS): Add it.
1342	* gelf_xlate.c: Include it.
1343	(__elf_xfctstom): Use elf_cvt_note.
1344	* elf_getdata.c (shtype_map, __libelf_type_align): Handle SHT_NOTE.
1345	(__libelf_set_rawdata): Likewise.
1346
13472007-08-19  Roland McGrath  <roland@redhat.com>
1348
1349	* gelf_update_auxv.c: New file.
1350	* gelf_getauxv.c: New file.
1351	* Makefile.am (libelf_a_SOURCES): Add them.
1352	* gelf.h: Declare gelf_getauxv, gelf_update_auxv.
1353	* libelf.map (ELFUTILS_1.3): New set, inherits fom ELFUTILS_1.2.
1354	Export gelf_getauxv, gelf_update_auxv.
1355
1356	* libelf.h (Elf_Type): Add ELF_T_AUXV.
1357	* abstract.h: Add auxv_t entries.
1358	* exttypes.h: Likewise.
1359	* gelf_xlate.h: Likewise.
1360	* gelf_xlate.c (__elf_xfctstom): Add ELF_T_AUXV entries.
1361	* gelf_fsize.c (__libelf_type_sizes): Likewise.
1362
13632007-08-12  Roland McGrath  <roland@redhat.com>
1364
1365	* elf32_updatefile.c (compare_sections): Sort secondarily on sh_size,
1366	and only tertiarily on index.
1367
13682007-07-09  Roland McGrath  <roland@redhat.com>
1369
1370	* elf.h: Update from glibc.
1371
13722007-04-22  Roland McGrath  <roland@redhat.com>
1373
1374	* elf.h: Update from glibc.
1375
13762007-03-18  Roland McGrath  <roland@redhat.com>
1377
1378	* elf_begin.c (get_shnum): Fix test for e_shoff being out of bounds.
1379	Return zero when the section headers do not fit within MAXSIZE.
1380
13812007-03-09  Roland McGrath  <roland@redhat.com>
1382
1383	* libelfP.h (LIBELF_EV_IDX): New macro.
1384	(__libelf_type_align): New macro.
1385	[! ALLOW_UNALIGNED]: Declare __libc_type_aligns array.
1386	* elf_getdata.c (shtype_map): Convert to just Elf_Type[][].
1387	(convert_data, __libelf_set_rawdata): Use that, __libelf_type_align,
1388	and __libelf_type_sizes, in place of old table.
1389	(__libc_type_aligns): New const variable.
1390
13912007-02-04  Ulrich Drepper  <drepper@redhat.com>
1392
1393	* Makefile (libelf.so): Build with -z relro.
1394
1395	* elf_begin.c (read_file): When using ELF_C_READ_MMAP use MAP_PRIVATE.
1396
13972007-01-30  Ulrich Drepper  <drepper@redhat.com>
1398
1399	* nlist.c: Close file descriptor before returning.
1400
14012007-01-20  Roland McGrath  <roland@redhat.com>
1402
1403	* gnuhash_xlate.h (elf_cvt_gnuhash): Fix fence-post error so we
1404	convert the final word.
1405
1406	* elf32_getshdr.c: Don't byteswap shdr fields when EI_DATA matches
1407	MY_ELFDATA on !ALLOW_UNALIGNED machines.
1408
14092007-01-18  Roland McGrath  <roland@redhat.com>
1410
1411	* gelf_rawchunk.c (gelf_rawchunk): Clear RESULT pointer after freeing
1412	it on read error.
1413
14142006-10-13  Roland McGrath  <roland@redhat.com>
1415
1416	* elf32_updatenull.c: Look for and accept phdr also for ET_CORE.
1417	* elf_error.c (msgstr): Change ELF_E_INVALID_PHDR string.
1418
14192006-08-29  Roland McGrath  <roland@redhat.com>
1420
1421	* elf32_getphdr.c: Don't byteswap phdr fields when EI_DATA matches
1422	MY_ELFDATA on !ALLOW_UNALIGNED machines.
1423	Reported by Christian Aichinger <Greek0@gmx.net>.
1424
1425	* Makefile.am (CLEANFILES): Add libelf.so.$(VERSION).
1426
14272006-08-08  Ulrich Drepper  <drepper@redhat.com>
1428
1429	* elf.h (DT_VALNUM): Update.
1430	(DT_ADDRNUM): Likewise.
1431
14322006-07-12  Ulrich Drepper  <drepper@redhat.com>
1433
1434	* elf32_updatefile.c: Adjust for internal_function_def removal.
1435	* elf32_updatenull.c: Likewise.
1436	* elf_begin.c: Likewise.
1437	* elf_getdata.c: Likewise.
1438
14392006-07-11  Ulrich Drepper  <drepper@redhat.com>
1440
1441	* libelf.h: Define ELF_T_GNUHASH.
1442	* elf_getdata.c (TYPEIDX): Handle SHT_GNU_HASH.
1443	(shtype_map): Add SHT_GNU_HASH entries.
1444	* gelf_xlate.c (__elf_xfctstom): Add ELF_T_GNUHASH entries.
1445	* gnuhash_xlate.h: New file.
1446	* Makefile.am (noinst_HEADERS): Add gnuhash_xlate.h.
1447
14482006-07-06  Ulrich Drepper  <drepper@redhat.com>
1449
1450	* elf_gnu_hash.c: New file.
1451	* libelf.h: Declare elf_gnu_hash.
1452	* Makefile.am (libelf_a_SOURCES): Add elf_gnu_hash.
1453	* libelf.map: Add elf_gnu_map for version ELFUTILS_1.2.
1454
14552006-06-15  Roland McGrath  <roland@redhat.com>
1456
1457	* libelf.h (elf_getarsym): Fix comment typo.
1458	Rename second parameter to be more explanatory.
1459	(elf_getident, elf_rawhide): Likewise.
1460
14612006-05-28  Ulrich Drepper  <drepper@redhat.com>
1462
1463	* elf32_updatefile.c (updatemmap): Preserve section content if
1464	copying would overwrite them.
1465	Fix msync paramters.
1466
14672006-04-04  Roland McGrath  <roland@redhat.com>
1468
1469	* elf32_updatefile.c (updatemmap): Handle other-endian case.
1470
14712006-04-04  Ulrich Drepper  <drepper@redhat.com>
1472
1473	* elf32_updatefile.c (updatemmap): Cleanups.  Remove shdr_dest
1474	variable.  Before writing sections, make a copy of the section
1475	header data if necessary.  Don't write section header while
1476	writing the section constent, it might overwrite some sections.
1477	Restore the pointer afterwards.
1478	* elf32_updatenull.c (updatenull): If the offset of a section in a
1479	file changed make sure we read the section so that it'll be written
1480	out.
1481
1482	* elf_update.c: Remove debug message.
1483
14842005-12-07  Roland McGrath  <roland@redhat.com>
1485
1486	* gelf_xlate.c [! ALLOW_UNALIGNED] (union unaligned): New type.
1487	(FETCH, STORE): New macros.
1488	(INLINE3): Use those to do alignment-friendly conversion.
1489
1490	* elf32_getshdr.c: Include map_address and start_offset in alignment
1491	calculations.
1492	* elf32_getphdr.c: Likewise.
1493
14942005-11-19  Roland McGrath  <roland@redhat.com>
1495
1496	* elf.h: Update from glibc.
1497
14982005-11-17  Roland McGrath  <roland@redhat.com>
1499
1500	* elf.h: Update from glibc.
1501
15022005-11-10  Roland McGrath  <roland@redhat.com>
1503
1504	* elf.h: Update from glibc.
1505
15062005-09-09  Roland McGrath  <roland@redhat.com>
1507
1508	* elf_update.c (write_file): Stat the file and fchmod it after update
1509	if its mode had S_ISUID or S_ISGID bits set.
1510
15112005-08-28  Ulrich Drepper  <drepper@redhat.com>
1512
1513	* elf32_getphdr.c: Include <system.h>.  Use pread_retry instead of
1514	pread.  And branch prediction where useful.
1515	* elf_begin.c: Likewise.
1516	* elf_getdata.c: Likewise.
1517	* elf_getshstrndx.c: Likewise.
1518	* elf_readall.c: Likewise.
1519	* gelf_rawchunk.c: Likewise.
1520	* elf32_updatefile.c: Include <system.h>.  Use pread_retry instead of
1521	pread.  And branch prediction where useful.
1522	* elf_getarsym.c: Don't define pread_retry here.
1523
1524	* Makefile.am: Use $(LINK) not $(CC) when creating DSO.
1525	(%.os): Use COMPILE.os.
1526	(COMPILE.os): Filter out gconv options.
1527
15282005-08-27  Ulrich Drepper  <drepper@redhat.com>
1529
1530	* elf_begin.c (file_read_elf): Avoid reading ELF header from file
1531	again.  Instead accept additional parameter which points to it if we
1532	don't use mmap.
1533	(get_shnum): Use passed in e_ident value as source of ELF header.
1534
15352005-08-15  Ulrich Drepper  <drepper@redhat.com>
1536
1537	* elf_begin.c (__libelf_next_arhdr): Use TEMP_FAILURE_RETRY.
1538
1539	* Makefile (libelf_a_SOURCES): Add elf_getaroff.c.
1540	* libelf.map: Export elf_getaroff.
1541	* libelf.h: Declare elf_getaroff.
1542	* elf_getaroff.c: New file.
1543
15442005-08-13  Ulrich Drepper  <drepper@redhat.com>
1545
1546	* elf_begin.c (get_shnum): Optimize memory handling.  Always read from
1547	mapped file if available.  Fix access to 64-bit sh_size.  Recognize
1548	overflow.
1549	(file_read_elf): Likewise.
1550
15512005-08-12  Roland McGrath  <roland@redhat.com>
1552
1553	* elf32_offscn.c: Do not match empty sections at OFFSET unless
1554	there are no nonempty sections at that offset.
1555
15562005-08-07  Ulrich Drepper  <drepper@redhat.com>
1557
1558	* elf.h: Update from glibc.
1559
15602005-08-06  Ulrich Drepper  <drepper@redhat.com>
1561
1562	* Makefile.am (AM_CFLAGS): Add -fpic when BUILD_STATIC.
1563
15642005-08-03  Ulrich Drepper  <drepper@redhat.com>
1565
1566	* libelf.map: Move elf32_offscn, elf64_offscn, and gelf_offscn in
1567	new version ELFUTILS_1.1.1.
1568
15692005-08-02  Ulrich Drepper  <drepper@redhat.com>
1570
1571	* elf_error.c: Add handling of ELF_E_INVALID_OFFSET.
1572	* elf32_offscn.c: New file.
1573	* elf64_offscn.c: New file.
1574	* gelf_offscn.c: New file.
1575	* Makefile.am (libelf_a_SOURCES): Add elf32_offscn.c, elf64_offscn.c,
1576	and gelf_offscn.c.
1577	* libelf.sym: Export new symbols.
1578
15792005-07-23  Ulrich Drepper  <drepper@redhat.com>
1580
1581	* elf-knowledge.h (SECTION_STRIP_P): Don't handle removal of debug
1582	sections here anymore.
1583	* elf32_checksum.c: Adjust for change in SECTION_STRIP_P interface.
1584
1585	* elf_update.c (elf_update): Get write lock, not read lock.
1586
1587	* elf32_updatenull.c (updatenull): Get section headers if necessary
1588	and possible.
1589
15902005-07-22  Ulrich Drepper  <drepper@redhat.com>
1591
1592	* elf32_updatenull.c (updatenull): If program header hasn't been loaded
1593	yet, try to do it now.
1594	Don't unnecessarily update overflow of section count in zeroth section
1595	sh_size field.
1596	If section content hasn't been read yet, do it before looking for the
1597	block size.  If no section data present, infer size of section header.
1598
15992005-05-11  Ulrich Drepper  <drepper@redhat.com>
1600
1601	* elf.h: Update again.
1602
16032005-05-09  Ulrich Drepper  <drepper@redhat.com>
1604
1605	* elf.h: Update from glibc.
1606
16072005-05-08  Roland McGrath  <roland@redhat.com>
1608
1609	* elf_begin.c (read_file) [_MUDFLAP]: Don't use mmap for now.
1610	* elf_update.c (write_file) [_MUDFLAP]: Likewise.
1611
16122005-03-29  Ulrich Drepper  <drepper@redhat.com>
1613
1614	* elf32_checksum.c: Use INTUSE and INTDEF to avoid PLTs.
1615	* elf_end.c: Likewise.
1616	* elf_getdata.c: Likewise.
1617	* gelf_getehdr.c: Likewise.
1618	* nlist.c: Likewise.
1619	* libelfP.h: Add declarations of internal functions.
1620
16212005-02-15  Ulrich Drepper  <drepper@redhat.com>
1622
1623	* common.h (CONVERT): Make sure all values are unsigned.
1624	(CONVERT_TO): Likewise.
1625
1626	* Makefile.am (AM_CFLAGS): Add -Wformat=2.
1627	Fix rule to build libelf.so.
1628
16292005-02-06  Ulrich Drepper  <drepper@redhat.com>
1630
1631	* Makefile.am: Cleanup AM_CFLAGS handling.  Add -Wunused -Wextra.
1632	Remove lint handling.
1633	* elf32_getphdr.c: Minor cleanups.
1634	* elf32_getshdr.c: Likewise.
1635	* elf32_updatefile.c: Likewise.
1636	* elf32_updatenull.c: Likewise.
1637	* elf_begin.c: Likewise.
1638	* elf_error.c: Likewise.
1639	* elf_getarsym.c: Likewise.
1640	* elf_getdata.c: Likewise.
1641	* elf_update.c: Likewise.
1642	* gelf_xlate.c: Likewise.
1643
16442005-02-05  Ulrich Drepper  <drepper@redhat.com>
1645
1646	* Makefile.am: Check for text relocations in constructed DSO.
1647
1648	* Makefile.am [MUDFLAP] (AM_CFLAGS): Add -Werror -fpic -fmudflap.
1649
16502005-02-04  Ulrich Drepper  <drepper@redhat.com>
1651
1652	* gelf_getehdr.c (gelf_getehdr): Slight optimization.
1653
1654	* elf32_checksum.c (checksum): Do not look at NOBITS sections.
1655
1656	* gelf.h: Add gelf_checksum prototype.
1657
16582004-09-25  Ulrich Drepper  <drepper@redhat.com>
1659
1660	* elf32_checksum.c: Make compile with gcc 4.0.
1661	* elf32_updatefile.c: Likewise.
1662	* elf32_updatenull.c: Likewise.
1663	* elf_begin.c: Likewise.
1664	* elf_error.c: Likewise.
1665	* elf_getdata.c: Likewise.
1666	* elf_getident.c: Likewise.
1667
16682004-04-01  Ulrich Drepper  <drepper@redhat.com>
1669
1670	* elf.h: Update from glibc.
1671
16722004-01-23  Ulrich Drepper  <drepper@redhat.com>
1673
1674	* elf_update.c: Fix locking.
1675	* elf_clone.c: Likewise.
1676
1677	* libelf.h: Define ELF_T_LIB.
1678	* gelf_getlib.c: New file.
1679	* gelf_update_lib.c: New file.
1680	* gelf.h: Declare the new functions.  Define GElf_Lib.
1681	* abstract.h: Define Lib, Lib32, Lib64.
1682	* gelf_xlate.c (__elf_xfctstom): Add ELF_T_LIB entry.
1683	* gelf_xlate.h: Add entry for ElfXX_Lib.
1684	* elf_getdata.c: Recognize SHT_GNU_LIBLIST as a known section type.
1685	* libelf.map: Add new symbols to ELFUTILS_1.1.
1686	* Makefile.am (libelf_a_SOURCES): Add gelf_getlib.c and
1687	gelf_update_lib.c.
1688
16892004-01-17  Ulrich Drepper  <drepper@redhat.com>
1690
1691	* Makefile.am: Support building with mudflap.
1692
1693	* gelf_xlate.c (INLINE3): Avoid using cast as lvalue.
1694	* dl-hash.h (_dl_elf_hash): Likewise.
1695
16962004-01-05  Ulrich Drepper  <drepper@redhat.com>
1697
1698	* elf-knowledge.h: New file.  From libelf subdir.
1699	* Makefile.am (euincludedir): Define.
1700	(euinclude_HEADERS): Add elf-knowledge.h.
1701
17022003-09-24  Ulrich Drepper  <drepper@redhat.com>
1703
1704	* elf.h: Define some PT_IA_64_HP_* constants.
1705
17062003-09-23  Jakub Jelinek  <jakub@redhat.com>
1707
1708	* libelfP.h (struct Elf): Move state.elf64.sizestr_offset after
1709	state.elf64.scnincr to match state.elf{,32}.
1710
17112003-08-12  Ulrich Drepper  <drepper@redhat.com>
1712
1713	* elf32_updatefile.c (__updatemmap): When writing back file where
1714	some sections have not been read in, count their sizes based on
1715	the section header.
1716
17172003-08-11  Ulrich Drepper  <drepper@redhat.com>
1718
1719	* Moved to CVS archive.
1720