util: Fix stack corruption in the m5 util
The number of arguments specified when calling parse_int_args() in do_exit() is incorrect. This leads to stack corruption since it causes writes past the end of the ints array.
This commit is contained in:
parent
8a767885d6
commit
35be32b7ea
1 changed files with 1 additions and 1 deletions
|
@ -130,7 +130,7 @@ do_exit(int argc, char *argv[])
|
||||||
usage();
|
usage();
|
||||||
|
|
||||||
uint64_t ints[1];
|
uint64_t ints[1];
|
||||||
parse_int_args(argc, argv, ints, 2);
|
parse_int_args(argc, argv, ints, 1);
|
||||||
m5_exit(ints[0]);
|
m5_exit(ints[0]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue