diff options
author | zhanghailiang <zhang.zhanghailiang@huawei.com> | 2014-11-17 13:57:34 +0800 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2014-11-17 13:59:23 +0100 |
commit | fae38221e78fc9f847965f6d18b359b8044df348 (patch) | |
tree | f34239a249594acc310c572682c63904d9fa9197 /hw/usb | |
parent | 0e8b439ae57ee3c46fb95e1775ea038d34496346 (diff) |
target-cris/translate.c: fix out of bounds read
In function t_gen_mov_TN_preg and t_gen_mov_preg_TN, The begin check about the
validity of in-parameter 'r' is useless. We still access cpu_PR[r] in the
follow code if it is invalid. Which will be an out-of-bounds read error.
Fix it by using assert() to ensure it is valid before using it.
Signed-off-by: zhanghailiang <zhang.zhanghailiang@huawei.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/usb')
0 files changed, 0 insertions, 0 deletions