Re: Some incorrect option sizes for PQconninfoOption in libpq

From: Daniel Gustafsson <daniel(at)yesql(dot)se>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Some incorrect option sizes for PQconninfoOption in libpq
Date: 2020-01-28 10:57:19
Message-ID: 03325A52-FB1F-4BA6-8050-66E31333AC5D@yesql.se
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> On 28 Jan 2020, at 06:36, Michael Paquier <michael(at)paquier(dot)xyz> wrote:

> I was reviewing the libpq code for the recent SSL protocol patch, and
> noticed two mistakes with dispsize for the following parameters:
> - channel_binding should be at 8, the largest value being "require".
> - gssencmode should be at 8.
>
> In those cases the zero-terminator was forgotten in the count. A
> similar mistake was done in the past for sslmode that was fixed by
> f4051e36. It is unlikely that dispsize is being used, but we cannot
> break that on compatibility grounds, and the current numbers are
> incorrect so let's fix it.
>
> Thoughts?

Nice catch! +1 on the attached patch.

cheers ./daniel

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2020-01-28 11:12:05 Re: ReadRecord wrongly assumes randAccess after 38a957316d.
Previous Message Kyotaro Horiguchi 2020-01-28 10:44:08 ReadRecord wrongly assumes randAccess after 38a957316d.