summaryrefslogtreecommitdiffstats
path: root/cddl
diff options
context:
space:
mode:
authormarkj <markj@FreeBSD.org>2014-09-22 21:02:38 +0000
committermarkj <markj@FreeBSD.org>2014-09-22 21:02:38 +0000
commit855d72feb3103c28b70b54b056a4b1d97d888ec3 (patch)
treed3621ae8339752fbeee1cb29153712b1bd360e25 /cddl
parent47910b28383b65a4839ea96b082c5f98c644f16d (diff)
downloadFreeBSD-src-855d72feb3103c28b70b54b056a4b1d97d888ec3.zip
FreeBSD-src-855d72feb3103c28b70b54b056a4b1d97d888ec3.tar.gz
Remove some variables that are no longer used as of r271413.
Reported by: Coverity CID: 1238924 X-MFC-With: r271413
Diffstat (limited to 'cddl')
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/drti.c14
1 files changed, 4 insertions, 10 deletions
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c b/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c
index 3c64f87..ccd4f9b 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c
@@ -121,12 +121,12 @@ dtrace_dof_init(void)
#if !defined(sun)
Elf *e;
Elf_Scn *scn = NULL;
- Elf_Data *symtabdata = NULL, *dynsymdata = NULL, *dofdata = NULL;
+ Elf_Data *dofdata = NULL;
dof_hdr_t *dof_next = NULL;
GElf_Shdr shdr;
int efd;
char *s;
- size_t shstridx, symtabidx = 0, dynsymidx = 0;
+ size_t shstridx;
#endif
if (getenv("DTRACE_DOF_INIT_DISABLE") != NULL)
@@ -166,15 +166,9 @@ dtrace_dof_init(void)
dof = NULL;
while ((scn = elf_nextscn(e, scn)) != NULL) {
gelf_getshdr(scn, &shdr);
- if (shdr.sh_type == SHT_SYMTAB) {
- symtabidx = shdr.sh_link;
- symtabdata = elf_getdata(scn, NULL);
- } else if (shdr.sh_type == SHT_DYNSYM) {
- dynsymidx = shdr.sh_link;
- dynsymdata = elf_getdata(scn, NULL);
- } else if (shdr.sh_type == SHT_SUNW_dof) {
+ if (shdr.sh_type == SHT_SUNW_dof) {
s = elf_strptr(e, shstridx, shdr.sh_name);
- if (s != NULL && strcmp(s, ".SUNW_dof") == 0) {
+ if (s != NULL && strcmp(s, ".SUNW_dof") == 0) {
dofdata = elf_getdata(scn, NULL);
dof = dofdata->d_buf;
}
OpenPOWER on IntegriCloud