From 114ffac2193093764276bb881324da01f0cbd7ff Mon Sep 17 00:00:00 2001 From: graydon Date: Tue, 13 Sep 2005 21:25:25 +0000 Subject: 2005-09-12 Graydon Hoare PR 1306 * tapsets.cxx (dwflpp::iterate_over_srcfile_lines): Fix two off-by-one errors in previous change. --- tapsets.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tapsets.cxx') diff --git a/tapsets.cxx b/tapsets.cxx index d7a2fb9b..7f3efcc1 100644 --- a/tapsets.cxx +++ b/tapsets.cxx @@ -599,7 +599,7 @@ dwflpp srcfile, lineno, 0, &srcsp, &nsrcs)); - if (need_single_match && nsrcs > 0) + if (need_single_match && nsrcs > 1) { // We wanted a single line record (a unique address for the // line) and we got a bunch of line records. We're going to @@ -610,7 +610,7 @@ dwflpp int lo_try = -1; int hi_try = -1; - for (size_t i = 0; i < 5; ++i) + for (size_t i = 1; i < 6; ++i) { if (lo_try == -1 && has_single_line_record(srcfile, lineno - i)) lo_try = lineno - i; -- cgit