From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Postgres hackers <pgsql-hackers(at)postgresql(dot)org> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Magnus Hagander <magnus(at)hagander(dot)net>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi> |
Subject: | Fix some error handling for read() and errno |
Date: | 2018-05-20 00:05:22 |
Message-ID: | 20180520000522.GB1603@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi all,
This is basically a new thread after what has been discussed for
pg_controldata with its error handling for read():
https://www.postgresql.org/message-id/CABUevEx8ZRV5Ut_FvP2etXiQppx3xVzm7oOaV3AcdHxX81Yt8Q%40mail.gmail.com
While reviewing the core code, I have noticed similar weird error
handling for read(). At the same time, some of those places may use an
incorrect errno, as an error is invoked using an errno which may be
overwritten by another system call. I found a funny one in slru.c,
for which I have added a note in the patch. I don't think that this is
worth addressing with more facility, thoughts are welcome.
Attached is a patch addressing the issues I found.
Thanks,
--
Michael
Attachment | Content-Type | Size |
---|---|---|
read-errno-handling.patch | text/x-diff | 10.9 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Gierth | 2018-05-20 00:36:10 | Re: Fix for FETCH FIRST syntax problems |
Previous Message | Michael Paquier | 2018-05-19 23:57:06 | Re: Fix for FETCH FIRST syntax problems |