summaryrefslogtreecommitdiff
path: root/libdw/fde.c
diff options
context:
space:
mode:
Diffstat (limited to 'libdw/fde.c')
-rw-r--r--libdw/fde.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/libdw/fde.c b/libdw/fde.c
index c8475f3e..2a59d3e1 100644
--- a/libdw/fde.c
+++ b/libdw/fde.c
@@ -90,6 +90,13 @@ intern_fde (Dwarf_CFI *cache, const Dwarf_FDE *entry)
}
fde->end += fde->start;
+ /* Make sure the fde actually covers a real code range. */
+ if (fde->start >= fde->end)
+ {
+ free (fde);
+ return (void *) -1;
+ }
+
fde->cie = cie;
if (cie->sized_augmentation_data)