[m-rev.] For review: Fix bug in mdb w.r.t. list_context_lines
Ralph Becket
rafe at csse.unimelb.edu.au
Fri Aug 18 15:56:02 AEST 2006
Branches: main
Estimated hours taken: 0.1
trace/mercury_trace_cmd_parameter.c:
Fix a fencepost bug that was causing the list_context_lines command to
segfault.
Index: trace/mercury_trace_cmd_parameter.c
===================================================================
RCS file: /home/mercury1/repository/mercury/trace/mercury_trace_cmd_parameter.c,v
retrieving revision 1.3
diff -u -r1.3 mercury_trace_cmd_parameter.c
--- trace/mercury_trace_cmd_parameter.c 6 Apr 2006 06:14:40 -0000 1.3
+++ trace/mercury_trace_cmd_parameter.c 18 Aug 2006 04:27:17 -0000
@@ -422,7 +422,7 @@
{
int n;
- if (word_count == 2 && MR_trace_is_natural_number(words[2], &n)) {
+ if (word_count == 2 && MR_trace_is_natural_number(words[1], &n)) {
MR_num_context_lines = n;
} else if (word_count == 1) {
fprintf(MR_mdb_out,
--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to: mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions: mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------
More information about the reviews
mailing list