From: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
---|---|
To: | Pg Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | psql lacking clearerr() |
Date: | 2021-03-24 14:11:41 |
Message-ID: | 20210324141141.GA3279@alvherre.pgsql |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
psql seems to never call clearerr() on its output file. So if it gets
an error while printing a result, it'll show
could not print result table: Success
after each and every result, even though the output file isn't in error
state anymore.
It seems that the simplest fix is just to do clearerr() at the start of
printTable(), as in the attached.
I haven't been able to find a good reproducer. Sometimes doing C-s C-c
does it, but I'm not sure it is fully reproducible.
--
Álvaro Herrera Valdivia, Chile
Attachment | Content-Type | Size |
---|---|---|
miss-clearerr.patch | text/x-diff | 440 bytes |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2021-03-24 14:39:42 | Re: [CLOBBER_CACHE]Server crashed with segfault 11 while executing clusterdb |
Previous Message | Magnus Hagander | 2021-03-24 13:42:11 | Re: shared memory stats: high level design decisions: consistency, dropping |