This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb] Don't reference past the end of the vector
- From: sergiodj+buildbot at sergiodj dot net
- To: gdb-testers at sourceware dot org
- Date: Fri, 09 Feb 2018 14:26:22 -0500
- Subject: [binutils-gdb] Don't reference past the end of the vector
- Authentication-results: sourceware.org; auth=none
*** TEST RESULTS FOR COMMIT 9c3630e983df43e68006b526a92c2a9a2b64dfd9 ***
Author: Tom Tromey <tom@tromey.com>
Branch: master
Commit: 9c3630e983df43e68006b526a92c2a9a2b64dfd9
Don't reference past the end of the vector
An earlier change made find_source_lines read:
end = &data[size];
However, since 'size' is the size of the vector, this seems fishy.
More obviously ok is to compute the end of the data directly:
end = data.data () + size;
2018-02-09 Tom Tromey <tom@tromey.com>
* source.c (find_source_lines): Don't reference past the end of
the vector.
- Follow-Ups:
- Failures on Fedora-s390x-m64, branch master
- Failures on Fedora-x86_64-m64, branch master
- Failures on Fedora-i686, branch master
- Failures on Fedora-x86_64-native-gdbserver-m32, branch master
- Failures on Fedora-x86_64-native-extended-gdbserver-m32, branch master
- Failures on Fedora-x86_64-m32, branch master
- Failures on Debian-s390x-native-extended-gdbserver-m64, branch master
- Failures on Ubuntu-AArch32-native-extended-gdbserver-m32, branch master
- Failures on Ubuntu-AArch32-native-gdbserver-m32, branch master
- Failures on Ubuntu-AArch32-m32, branch master
- Failures on Ubuntu-AArch64-m64, branch master