summaryrefslogtreecommitdiffstats
path: root/src/elfcmp.c
Commit message (Collapse)AuthorAgeFilesLines
* Open files in O_BINARYUlf Hermann2017-05-081-1/+1
| | | | | | | | | If O_BINARY is not defined, define it to 0, so that the change has no effect then. Some systems have separate binary and text modes for files, and we don't want the text mode to be used. Change-Id: If7efb5bd448c2a1c7d1eb5dab276849b1b15a3ce Reviewed-by: Christian Kandeler <[email protected]>
* Use the empty string for note names with zero size (without any data).Mark Wielaard2017-04-031-2/+4
| | | | | | | | | | ELF notes can have a zero sized name. In which case there is no data at all (so also no zero terminator). Make sure to use the empty string for such notes if the code does not otherwise explicitly check n_namesz. https://sourceware.org/bugzilla/show_bug.cgi?id=21300 Signed-off-by: Mark Wielaard <[email protected]>
* Move print_version into printversion.{h|c}Ulf Hermann2017-02-171-1/+1
| | | | | | | | Rename version.c so that the implementation is called after the header and the header doesn't clash with the toplevel version.h. print_version depends on argp and is only used in the tools. Signed-off-by: Ulf Hermann <[email protected]>
* http://elfutils.org/ is now hosted at http://sourceware.org/elfutils/Mark Wielaard2016-12-241-15/+0
| | | | | | | | | | | | | | | | | fedorahosted used to be our home, but we are now hosted at sourceware. Change the elfutils project home to http://elfutils.org/ Point hosted services (email, release, git, bug tracker and web pages) to https://sourceware.org/elfutils/ Move design notes from README to NOTES. Add URLs for home, releases, bugs, git and mailinglist to README. Make the --version output of all tools the same by using a common print_version function and update the publicly shown copyright holder to the elfutils developers. Signed-off-by: Mark Wielaard <[email protected]>
* elfcmp: fix self-comparison error with GCC 6David Abdurachmanov2016-04-111-1/+1
| | | | | | | | | | | | Noticed with Fedora 24 Alpha, gcc (GCC) 6.0.0 20160406 (Red Hat 6.0.0-0.20). elfcmp.c: In function ‘main’: elfcmp.c:364:199: error: self-comparison always evaluates to false [-Werror=tautological-compare] if (unlikely (name1 == NULL || name2 == NULL Signed-off-by: David Abdurachmanov <[email protected]>
* elfcmp: Fix leaking Ebl handles.Mark Wielaard2016-01-021-0/+2
| | | | | | | open_file () explicitly gets Ebl handles for both Elf files to compare. Make sure to close those when done. Signed-off-by: Mark Wielaard <[email protected]>
* elfcmp: Don't call memcmp with possible NULL d_buf.Mark Wielaard2015-06-051-1/+2
| | | | | | When d_size is zero d_buf might be NULL. Signed-off-by: Mark Wielaard <[email protected]>
* elfcmp: Add some NULL and zero checks.Mark Wielaard2015-01-151-7/+13
| | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1170810#c17 Reported-by: Alexander Cherepanov <[email protected]> Signed-off-by: Mark Wielaard <[email protected]>
* elfcmp: Make sure Elf32_Word difference doesn't wrap around in int compare.Mark Wielaard2014-12-171-2/+1
| | | | Signed-off-by: Mark Wielaard <[email protected]>
* Check elf_strptr didn't fail getting section name.Mark Wielaard2014-11-171-2/+3
| | | | | | | | Since elf_strptr can fail and return NULL we should always check the result before usage. Debug sections are only handled by section name, so make sure the name actually exists. Signed-off-by: Mark Wielaard <[email protected]>
* Update name, license and contributor policy.Mark Wielaard2012-06-051-19/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Change name from "Red Hat elfutils" to "elfutils". * Update license of standalone tools and test from GPLv2 to GPLv3+. * Change license of libraries from GPLv2+exception to GPLv2/LGPLv3+. * Add Developer Certificate of Origin based contributor policy. top-level: - COPYING: Upgraded from GPLv2 to GPLv3. - CONTRIBUTING, COPYING-GPLv2, COPYING-LGPLv3: New files. - NEWS: Added note about new contribution and license policy. - Makefile.am: Updated to GPLv3, added new files to EXTRA_DIST. - configure.ac: Update to GPLv3, changed AC_INIT name to 'elfutils'. backends, lib, libasm, libcpu, libdw, libdwfl, libebl, libelf: - All files updated to GPLv2/LGPLv3+. Except some very small files (<5 lines) which didn't have any headers at all before, the linker .maps files and the libcpu/defs files which only contain data and libelf/elf.h which comes from glibc and is under LGPLv2+. config: - elfutils.spec.in: Add new License: headers and new %doc files. - Update all license headers to GPLv2/LGPLv3+ for files used by libs. src, tests: - All files updated to GPLv3+. Except for the test bz2 data files, the linker maps and script files and some very small files (<5 lines) that don't have any headers. Signed-off-by: Richard Fontana <[email protected]> Signed-off-by: Mark Wielaard <[email protected]>
* Update copyright yearUlrich Drepper2012-01-211-4/+4
|
* elfcmp: Add --l/--verbose flag.Roland McGrath2011-02-111-36/+46
|
* elfcmp: Add --ignore-build-id flag.Roland McGrath2011-02-111-1/+114
|
* Handle extended phnum in elflint and elfcmp.Roland McGrath2010-01-071-3/+36
|
* Make elfcmp exit 2 for trouble and 1 only for mismatch, like all its cousins.Roland McGrath2009-01-211-17/+17
|
* Move argp_program_version_hook and argp_program_bug_address variablesUlrich Drepper2009-01-171-2/+3
| | | | in all programs into the .rodata section.
* Unpdate copyright in messages.Ulrich Drepper2009-01-011-2/+2
|
* Finish elflint .gnu.attributes checkingRoland McGrath2008-02-211-2/+4
|
* propagate from branch 'com.redhat.elfutils.disasm' (head ↵Ulrich Drepper2008-01-021-0/+3
| | | | | | d15b4eb794e81e477f9896fe82a74cb5ecf4514c) to branch 'com.redhat.elfutils' (head eaacbf01f8cc89d043ec6eca9b5e35cb5c4cde06)
* Update copyright year.Ulrich Drepper2008-01-021-1/+1
|
* Prepare for 0.128 release.Ulrich Drepper2007-06-061-3/+3
| | | | | | Minor fixes. Update gettext files to 0.16.1.
* 2007-04-24 Roland McGrath <[email protected]>Roland McGrath2007-04-251-3/+112
| | | | | * run-strip-test.sh: When we saved the debug info, test unstrip too.
* Update copyright year.elfutils-0.125Ulrich Drepper2007-01-101-2/+2
|
* Fix FSF address. No exception for libdwarf.Ulrich Drepper2006-04-041-1/+1
|
* Prepare for 0.120 release.Ulrich Drepper2006-04-041-2/+2
|
* propagate from branch 'com.redhat.elfutils.roland.pending' (head ↵Ulrich Drepper2006-04-041-9/+21
| | | | | | 4f8fc821345feef58624f0aa5b470d4827577d8c) to branch 'com.redhat.elfutils' (head 76e26cb54695fd3b21ee8fb5be3036bd68200633)
* Cleanup of messages.Ulrich Drepper2005-09-031-42/+43
|
* Relax elfcmp to ignore section count and the position of the sectionUlrich Drepper2005-08-011-3/+1
| | | | name string table position.
* elfcmp.c: Include <locale.h>.Roland McGrath2005-07-281-0/+1
|
* elfcmp.c: Print name and index of differing section.Ulrich Drepper2005-07-271-11/+25
|
* Adjust for monotone.Ulrich Drepper2005-07-261-0/+611