From: | Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com> |
---|---|
To: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> |
Cc: | Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, Euler Taveira <euler(at)eulerto(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: logicalrep_message_type throws an error |
Date: | 2023-07-17 13:49:42 |
Message-ID: | CAExHW5vvhhtdv-LctC5Wz-yuyh1me3KtvyuOqX48BRQicDGTJg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Sat, Jul 15, 2023 at 12:57 PM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> >
> > Since the numerical value is important only in invalid message type
> > cases, how about using a format like "??? (88)" in unknown message
> > type cases, in both error and context messages?
> >
>
> Do you have something like attached in mind?
Prologue of psprintf() says
* Errors are not returned to the caller, but are reported via elog(ERROR)
* in the backend, or printf-to-stderr-and-exit() in frontend builds.
* One should therefore think twice about using this in libpq.
If an error occurs in psprintf(), it will throw an error which will
override the original error. I think we should avoid any stuff that
throws further errors.
--
Best Wishes,
Ashutosh Bapat
From | Date | Subject | |
---|---|---|---|
Next Message | Aleksander Alekseev | 2023-07-17 14:11:46 | Re: Getting rid of OverrideSearhPath in namespace.c |
Previous Message | Seraphime Kirkovski | 2023-07-17 13:16:02 | Fine-tune TLS 1.3 cipher suites and curves lists |