From: Tom Tromey <tom@tromey.com>
To: Tom de Vries <tdevries@suse.de>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH] [gdb/tui] Fix segfault in tui_win_info::forward_scroll
Date: Wed, 21 Oct 2026 10:43:02 -0600 [thread overview]
Message-ID: <87fqxzypgp.fsf@tromey.com> (raw)
In-Reply-To: <20261021115918.443487-1-tdevries@suse.de> (Tom de Vries's message of "Wed, 21 Oct 2026 13:59:18 +0200")
>>>>> "Tom" == Tom de Vries <tdevries@suse.de> writes:
Tom> Dereferencing begin () for an empty range means dereferencing end (), which is
Tom> undefined behavior. But it happens to set *win_to_scroll to nullptr.
Thanks.
Tom> This behavior is not specified in the documentation or help message, not
Tom> checked in the testsuite and not replicated in any of the other scroll
Tom> methods.
Tom> So an alternative way of fixing this would be to drop the special treatment of
Tom> the command window in parse_scrolling_args, and fix both PRs that way.
I think the choice you made makes sense.
Even if scrolling the command window was possible (there's various bugs
open about this, but it's non-trivial to fix), I think having "+" scroll
it still wouldn't really make sense.
Approved-By: Tom Tromey <tom@tromey.com>
Tom
prev parent reply other threads:[~2026-10-21 16:44 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-21 11:59 Tom de Vries
2026-10-21 16:43 ` Tom Tromey [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=87fqxzypgp.fsf@tromey.com \
--to=tom@tromey.com \
--cc=gdb-patches@sourceware.org \
--cc=tdevries@suse.de \
/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