Test "set width/height -1"

As a follow up to the previous commit, add a test for "set
width/height -1", to make sure we don't overflow in readline with
negative values either.

gdb/testsuite/ChangeLog:
2019-02-27  Pedro Alves  <palves@redhat.com>

	* gdb.base/page.exp: Add tests for "set width/height -1".
This commit is contained in:
Pedro Alves 2019-02-27 18:48:37 +00:00
parent 8ed252144a
commit 5862844d0f
2 changed files with 7 additions and 0 deletions

View File

@ -1,3 +1,7 @@
2019-02-27 Pedro Alves <palves@redhat.com>
* gdb.base/page.exp: Add tests for "set width/height -1".
2019-02-27 Pedro Alves <palves@redhat.com>
* gdb.base/page.exp: Add tests for "set/show width/height" with

View File

@ -118,6 +118,9 @@ foreach_with_prefix size {"0" "0x80000000" "unlimited"} {
"Number of lines gdb thinks are in a page is unlimited\\."
}
gdb_test "set width -1" "integer -1 out of range"
gdb_test "set height -1" "integer -1 out of range"
gdb_exit
return 0