richardphibel / rpms / rpm

Forked from rpms/rpm 2 years ago
Clone
672c60
From 00a0afd5e079a73ef6871f1538f34fa4e67892e6 Mon Sep 17 00:00:00 2001
672c60
Message-Id: <00a0afd5e079a73ef6871f1538f34fa4e67892e6.1573552234.git.pmatilai@redhat.com>
672c60
In-Reply-To: <ce6e8556a8f93327d6de0446f21ac5e549861d82.1573552234.git.pmatilai@redhat.com>
672c60
References: <ce6e8556a8f93327d6de0446f21ac5e549861d82.1573552234.git.pmatilai@redhat.com>
672c60
From: Mark Wielaard <mark@klomp.org>
672c60
Date: Mon, 17 Jun 2019 11:23:26 +0200
672c60
Subject: [PATCH 3/3] debugedit: Make sure .debug_line old/new idx start equal.
672c60
672c60
Found by running the debugedit tests under valgrind.
672c60
If the old and new .debug_line offset isn't changed then we might
672c60
write out an uninitialized new_idx.
672c60
---
672c60
 tools/debugedit.c | 1 +
672c60
 1 file changed, 1 insertion(+)
672c60
672c60
diff --git a/tools/debugedit.c b/tools/debugedit.c
672c60
index 84483ef5e..9f8dcd0fb 100644
672c60
--- a/tools/debugedit.c
672c60
+++ b/tools/debugedit.c
672c60
@@ -1177,6 +1177,7 @@ get_line_table (DSO *dso, size_t off, struct line_table **table)
672c60
   *table = NULL;
672c60
 
672c60
   t->old_idx = off;
672c60
+  t->new_idx = off;
672c60
   t->size_diff = 0;
672c60
   t->replace_dirs = false;
672c60
   t->replace_files = false;
672c60
-- 
672c60
2.23.0
672c60