diff options
author | emaste <emaste@FreeBSD.org> | 2016-02-10 19:39:36 +0000 |
---|---|---|
committer | emaste <emaste@FreeBSD.org> | 2016-02-10 19:39:36 +0000 |
commit | 85217dee0e24c5f3ac285420e843063b4b52c1a0 (patch) | |
tree | 3de9500b684e6cb0b1066dfbf0133793e385df71 /libdwarf/dwarf_str.c | |
parent | 08c7091d4a30fde09fdda23d2016d8d11624cb15 (diff) | |
download | FreeBSD-src-85217dee0e24c5f3ac285420e843063b4b52c1a0.zip FreeBSD-src-85217dee0e24c5f3ac285420e843063b4b52c1a0.tar.gz |
Import ELF Tool Chain snapshot revision 3395
This is close to the upcoming 0.7.1 release.
From http://svn.code.sf.net/p/elftoolchain/code
Diffstat (limited to 'libdwarf/dwarf_str.c')
-rw-r--r-- | libdwarf/dwarf_str.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libdwarf/dwarf_str.c b/libdwarf/dwarf_str.c index 71a7f75..c402f21 100644 --- a/libdwarf/dwarf_str.c +++ b/libdwarf/dwarf_str.c @@ -26,7 +26,7 @@ #include "_libdwarf.h" -ELFTC_VCSID("$Id: dwarf_str.c 2075 2011-10-27 03:47:28Z jkoshy $"); +ELFTC_VCSID("$Id: dwarf_str.c 3295 2016-01-08 22:08:10Z jkoshy $"); int dwarf_get_str(Dwarf_Debug dbg, Dwarf_Off offset, char **string, @@ -34,7 +34,7 @@ dwarf_get_str(Dwarf_Debug dbg, Dwarf_Off offset, char **string, { Dwarf_Section *ds; - if (dbg == NULL || offset < 0 || string == NULL || ret_strlen == NULL) { + if (dbg == NULL || string == NULL || ret_strlen == NULL) { DWARF_SET_ERROR(dbg, error, DW_DLE_ARGUMENT); return (DW_DLV_ERROR); } @@ -45,12 +45,12 @@ dwarf_get_str(Dwarf_Debug dbg, Dwarf_Off offset, char **string, return (DW_DLV_NO_ENTRY); } - if ((Dwarf_Unsigned) offset > ds->ds_size) { + if (offset > ds->ds_size) { DWARF_SET_ERROR(dbg, error, DW_DLE_ARGUMENT); return (DW_DLV_ERROR); } - if ((Dwarf_Unsigned) offset == ds->ds_size) { + if (offset == ds->ds_size) { DWARF_SET_ERROR(dbg, error, DW_DLE_NO_ENTRY); return (DW_DLV_NO_ENTRY); } |