ltrace: 7.2 -> 7.3

Upgrade ltrace from 7.2 to 7.3.

* update SRC_URI and SRCREV
* drop backport patch 0001-In-Linux-backend-initialize-linkmap-struct.patch
* fix error when compile with gcc 5.2

Signed-off-by: Kai Kang <kai.kang@windriver.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
This commit is contained in:
Kai Kang
2015-08-24 23:31:54 +08:00
committed by Martin Jansa
parent f45881b382
commit 31c98b41c3
3 changed files with 42 additions and 35 deletions

View File

@@ -1,31 +0,0 @@
From efd12cfb10ccd2c612838c0e22069554ce60637c Mon Sep 17 00:00:00 2001
From: Petr Machata <pmachata@redhat.com>
Date: Wed, 2 Jan 2013 16:01:43 +0100
Subject: [PATCH] In Linux backend, initialize linkmap struct
GCC 4.7.2 -m32 -Os gives the following (spurious) warning:
proc.c: In function 'crawl_linkmap':
proc.c:544:25: error: 'rlm.l_addr' may be used uninitialized in this
Upstream-Status: Backport
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
sysdeps/linux-gnu/proc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sysdeps/linux-gnu/proc.c b/sysdeps/linux-gnu/proc.c
index 6e01d28..d69c985 100644
--- a/sysdeps/linux-gnu/proc.c
+++ b/sysdeps/linux-gnu/proc.c
@@ -484,7 +484,7 @@ crawl_linkmap(struct process *proc, struct lt_r_debug_64 *dbg)
arch_addr_t addr = (arch_addr_t)(uintptr_t)dbg->r_map;
while (addr != 0) {
- struct lt_link_map_64 rlm;
+ struct lt_link_map_64 rlm = {};
if (lm_fetcher(proc)(proc, addr, &rlm) < 0) {
debug(2, "Unable to read link map");
return;
--
2.3.5

View File

@@ -0,0 +1,38 @@
From 876fe5680d77800426f8c4c5680a235732d722e6 Mon Sep 17 00:00:00 2001
From: Kai Kang <kai.kang@windriver.com>
Date: Mon, 24 Aug 2015 17:37:54 +0800
Subject: [PATCH] ltrace: fix gcc 5 logical not parentheses
Upstream-Status: Pending
Build ltrace with gcc 5.2, it fails with:
error: logical not is only applied to the left hand side of comparison
[-Werror=logical-not-parentheses]
if (!need_data(data, offset, SIZE / 8) < 0) \
^
Function need_data just return 0 on success and -1 if fail. So it is ok
to just test if (need_data(data, offset, SIZE / 8) < 0).
Signed-off-by: Kai Kang <kai.kang@windriver.com>
---
ltrace-elf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ltrace-elf.c b/ltrace-elf.c
index c571d2a..7fe830f 100644
--- a/ltrace-elf.c
+++ b/ltrace-elf.c
@@ -218,7 +218,7 @@ need_data(Elf_Data *data, GElf_Xword offset, GElf_Xword size)
int \
NAME(Elf_Data *data, GElf_Xword offset, uint##SIZE##_t *retp) \
{ \
- if (!need_data(data, offset, SIZE / 8) < 0) \
+ if (need_data(data, offset, SIZE / 8) < 0) \
return -1; \
\
if (data->d_buf == NULL) /* NODATA section */ { \
--
1.9.1