From: Pedro Alves <palves@redhat.com>
To: Kevin Buettner <kevinb@redhat.com>, Tom Tromey <tom@tromey.com>
Cc: gdb-patches@sourceware.org, Saagar Jha <saagar@saagarjha.com>
Subject: [PATCH] Test "set width/height -1" (Re: [PATCH 2/2] Make 'show width/height' display "unlimited" when capped for readline)
Date: Wed, 27 Feb 2019 18:52:00 -0000 [thread overview]
Message-ID: <5e5690c4-56f5-dec6-d6e0-8e3ca75a7929@redhat.com> (raw)
In-Reply-To: <12d810aa-a0fe-429a-fac2-255197076763@redhat.com>
On 02/27/2019 06:50 PM, Pedro Alves wrote:
> On 02/20/2019 11:01 PM, Kevin Buettner wrote:
>> On Wed, 20 Feb 2019 14:04:28 -0700
>> Tom Tromey <tom@tromey.com> wrote:
>>
>>>>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:
>>>
>>> Pedro> So how about this version instead?
>>>
>>> Pedro> And this as a follow up?
>>>
>>> These both look good to me.
>>> Thanks for following up on this.
>>
>> LGTM too.
> Thanks. I've checked these in now.
And this obvious follow up too.
From 5862844d0f443b9f65e8dd0d85c43f8818d3f355 Mon Sep 17 00:00:00 2001
From: Pedro Alves <palves@redhat.com>
Date: Wed, 27 Feb 2019 18:48:37 +0000
Subject: [PATCH] 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".
---
gdb/testsuite/ChangeLog | 4 ++++
gdb/testsuite/gdb.base/page.exp | 3 +++
2 files changed, 7 insertions(+)
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index b5177c7e07..29b2832764 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -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
diff --git a/gdb/testsuite/gdb.base/page.exp b/gdb/testsuite/gdb.base/page.exp
index 8f1698c26e..68d94b38a3 100644
--- a/gdb/testsuite/gdb.base/page.exp
+++ b/gdb/testsuite/gdb.base/page.exp
@@ -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
--
2.14.4
prev parent reply other threads:[~2019-02-27 18:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-27 4:56 [PATCH] Prevent overflow in rl_set_screen_size Saagar Jha
2019-02-15 1:52 ` Kevin Buettner
2019-02-15 9:40 ` Pedro Alves
2019-02-15 10:52 ` Saagar Jha
2019-02-15 20:19 ` Tom Tromey
[not found] ` <d3e1b041-9802-1fb2-2d5f-73590287610e@redhat.com>
2019-02-20 17:22 ` Pedro Alves
2019-02-20 17:37 ` [PATCH 2/2] Make 'show width/height' display "unlimited" when capped, for readline (Re: [PATCH] Prevent overflow in rl_set_screen_size) Pedro Alves
2019-02-20 21:04 ` Tom Tromey
2019-02-20 23:02 ` Kevin Buettner
2019-02-27 18:51 ` Pedro Alves
2019-02-27 18:52 ` Pedro Alves [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5e5690c4-56f5-dec6-d6e0-8e3ca75a7929@redhat.com \
--to=palves@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=kevinb@redhat.com \
--cc=saagar@saagarjha.com \
--cc=tom@tromey.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox