On Tue 2015-08-11 11:47 -0400, Dave Anderson wrote:
[ ... ]
The bug is caused by this part of the 2/2 patch:
@@ -1655,8 +1660,15 @@ cmd_dis(void)
extract_hex(buf2, &curaddr, ':', TRUE);
+ if (forward) {
+ if (curaddr != target)
+ continue;
+ else
+ forward = FALSE;
+ }
+
if (!reverse)
- if ((req->flags & GNU_FUNCTION_ONLY) &&
+ if (!count_entered &&
(curaddr >= req->addr2))
break;
req->addr2 is 0 in this case, so it always breaks/fails.
Indeed; req->addr2 is only relevant in the case of: reverse, forward
or GNU_FUNCTION_ONLY. Where a single instruction is specified, we should
not evaluate here. As such the following change should resolve this bug:
--- a/kernel.c
+++ b/kernel.c
@@ -1669,7 +1669,7 @@ cmd_dis(void)
}
if (!reverse)
- if (!count_entered &&
+ if (!count_entered && req->addr2 &&
(curaddr >= req->addr2))
break;
--
Aaron Tomlin