[PATCH] Fix the processing of Meta-key commands in TUI

Patrick Palka patrick@parcs.ath.cx
Fri Nov 14 19:12:00 GMT 2014


On Thu, Aug 28, 2014 at 12:13 PM, Pedro Alves <palves@redhat.com> wrote:
> On 08/28/2014 03:18 PM, Patrick Palka wrote:
>> On Thu, Aug 28, 2014 at 7:31 AM, Pedro Alves <palves@redhat.com> wrote:
>>> On 08/22/2014 09:44 PM, Patrick Palka wrote:
>>>> +
>>>> +  if (async_command_editing_p && key_is_start_sequence (ch))
>>>
>>> I think the key_is_start_sequence check means that we'll
>>> fail to compensate in case the sequence if longer than
>>> 2 bytes?  That is, we'll compensate for the second char,
>>> but fail to compensate for the third, because by then,
>>> ch will not be a start sequence key.
>>
>> Yes I think so.  I only took into account common 2-byte sequences such
>> as Alt_F.  I suppose that the check could be removed to account for
>> 3+-byte key sequences too, but I haven't thought out the consequences
>> of such change.  And I'm not sure that readline uses any of such
>> sequences.
>
> It's fine with me to leave this as is, if we add a comment
> mentioning this issue.
>
> Thanks,
> Pedro Alves
>

Attached is the patch that Pedro approved, augmented with a comment
describing the potential problem with 3+ byte sequences.  I wonder if
someone could commit this for me?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Fix-the-processing-of-Meta-key-commands-in-TUI.patch
Type: application/octet-stream
Size: 4568 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20141114/e0f11d83/attachment.obj>


More information about the Gdb-patches mailing list