This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb] Fix GDBHISTSIZE test failure on i686
- From: sergiodj+buildbot at redhat dot com
- To: gdb-testers at sourceware dot org
- Date: Tue, 23 Jun 2015 18:27:18 -0400
- Subject: [binutils-gdb] Fix GDBHISTSIZE test failure on i686
- Authentication-results: sourceware.org; auth=none
*** TEST RESULTS FOR COMMIT 0fc26cafacfff9f53d898bb73495b384b80d6d31 ***
Author: Patrick Palka <patrick@parcs.ath.cx>
Branch: master
Commit: 0fc26cafacfff9f53d898bb73495b384b80d6d31
Fix GDBHISTSIZE test failure on i686
The test
test_histsize_history_setting "99999999999999999999999999999999999" "unlimited"
was failing on i686 because the condition in init_history() for
determining whether to map a large GDBHISTSIZE value to infinity was
long var = strtol (tmpenv);
if (var > INT_MAX)
history_size = unlimited;
but this condition is never true on i686 because INT_MAX == LONG_MAX.
So in order to properly map large out-of-range values of GDBHISTSIZE to
infinity on targets where LONG_MAX > INT_MAX as well as on i686, we have
to instead change the above condition to
if (var > INT_MAX
|| (var == INT_MAX && errno == ERANGE))
history_size = unlimited;
gdb/ChangeLog:
* top.c (init_history): Look at errno after calling strtol to
properly map large GDBHISTSIZE values to infinity.
- Follow-Ups:
- Failures on Fedora-s390x-m64, branch master
- Failures on AIX-POWER7-plain, branch master
- Failures on Fedora-ppc64be-cc-with-index, branch master
- Failures on Fedora-ppc64be-m64, branch master
- Failures on Debian-i686, branch master
- Failures on Fedora-ppc64be-native-gdbserver-m64, branch master
- Failures on Debian-i686-native-gdbserver, branch master
- Failures on Fedora-ppc64be-native-extended-gdbserver-m64, branch master
- Failures on Debian-i686-native-extended-gdbserver, branch master
- Failures on Fedora-ppc64le-native-extended-gdbserver-m64, branch master
- Failures on Debian-x86_64-native-extended-gdbserver-m64, branch master
- Failures on Debian-x86_64-m64, branch master
- Failures on Debian-x86_64-native-gdbserver-m64, branch master
- Failures on Fedora-x86_64-native-gdbserver-m64, branch master
- Failures on Fedora-x86_64-m64, branch master