Re: Deleting prepared statements from libpq.

From: Jelte Fennema <me(at)jeltef(dot)nl>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: jian he <jian(dot)universality(at)gmail(dot)com>, Dmitry Igrishin <dmitigr(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Daniele Varrazzo <daniele(dot)varrazzo(at)gmail(dot)com>
Subject: Re: Deleting prepared statements from libpq.
Date: 2023-06-23 07:39:00
Message-ID: CAGECzQTkShHecFF+EZrm94Lbsu2ej569T=bz+PjMbw9Aiioxuw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, 23 Jun 2023 at 05:59, Michael Paquier <michael(at)paquier(dot)xyz> wrote:
> [...]
> res = PQgetResult(conn);
> if (res == NULL)
> - pg_fatal("expected NULL result");
> + pg_fatal("expected non-NULL result");
>
> This should check for the NULL-ness of the result returned for
> PQclosePrepared() rather than changing the behavior of the follow-up
> calls?

To be clear, it didn't actually change the behaviour. I only changed
the error message, since it said the exact opposite of what it was
expecting. I split this minor fix into its own commit now to clarify
that. I think it would even make sense to commit this small patch to
the PG16 branch, since it's a bugfix in the tests (and possibly even
back-patch to others if that's not a lot of work). I changed the error
message to be in line with one from earlier in the test.

I addressed all of your other comments.

Attachment Content-Type Size
v6-0002-Support-sending-Close-messages-from-libpq.patch application/octet-stream 22.1 KB
v6-0001-Correct-error-message-in-test_prepared.patch application/octet-stream 1.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Ashutosh Bapat 2023-06-23 07:43:44 Re: Infinite Interval
Previous Message Konstantin Knizhnik 2023-06-23 07:35:50 Index range search optimization