Re: fix for readline terminal size problems when window is resized with open pager

Поиск
Список
Период
Сортировка
От Merlin Moncure
Тема Re: fix for readline terminal size problems when window is resized with open pager
Дата
Msg-id CAHyXU0xTu6QWRR3H3SX_y=MnaPZOHaqL_=ZyewwQ7MTYgUvd8A@mail.gmail.com
обсуждение исходный текст
Ответ на Re: fix for readline terminal size problems when window is resized with open pager  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: fix for readline terminal size problems when window is resized with open pager  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Wed, Dec 16, 2015 at 2:12 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Merlin Moncure <mmoncure@gmail.com> writes:
>> On Wed, Dec 16, 2015 at 1:29 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>>> So I now think that print.c shouldn't be involved at all, and the right
>>> thing to do is just have gets_interactive() invoke the resize function
>>> immediately before calling readline().  That will still leave a window
>>> for SIGWINCH to be missed, but it's a pretty tiny one.
>
>> right -- agreed.
>
> I tried that and found out that the first call dumps core because readline
> hasn't been initialized yet.  To fix that, we need an explicit call to
> rl_initialize() instead of depending on readline() to do it for us.
> So I arrive at the attached modified patch.

This is working great.  Is there anything left for me to do here?

merlin



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Craig Ringer
Дата:
Сообщение: Remove Windows crash dump support?
Следующее
От: Magnus Hagander
Дата:
Сообщение: Re: Remove Windows crash dump support?