This patch fixes the "mdump" and "medit" shell commands:
- "mdump" got the length argument wrong and would only produce useful
output if it was omitted.
- "medit" overran the argument list, choking on the NULL pointer
following the last argument.
Note that "medit" still only does byte-sized accesses, which limits
its usefulness on most systems.
- Werner
old
|
new
|
|
47 | 47 | } |
48 | 48 | |
49 | 49 | if (argc > 2) { |
50 | | if ( rtems_string_to_int(argv[1], &max, NULL, 0) ) { |
51 | | printf( "Length argument (%s) is not a number\n", argv[1] ); |
| 50 | if ( rtems_string_to_int(argv[2], &max, NULL, 0) ) { |
| 51 | printf( "Length argument (%s) is not a number\n", argv[2] ); |
52 | 52 | return -1; |
53 | 53 | } |
54 | 54 | if (max <= 0) { |