postgresql/src/backend/utils/cache
Michael Paquier e41d0a1090 Add proper errcodes to new error messages for read() failures
Those would use the default ERRCODE_INTERNAL_ERROR, but for foreseeable
failures an errcode ought to be set, ERRCODE_DATA_CORRUPTED making the
most sense here.

While on the way, fix one errcode_for_file_access missing in origin.c
since the code has been created, and remove one assignment of errno to 0
before calling read(), as this was around to fit with what was present
before 811b6e36 where errno would not be set when not enough bytes are
read.  I have noticed the first one, and Tom has pinged me about the
second one.

Author: Michael Paquier
Reported-by: Tom Lane
Discussion: https://postgr.es/m/27265.1531925836@sss.pgh.pa.us
2018-07-23 09:37:36 +09:00
..
attoptcache.c Update copyright for 2018 2018-01-02 23:30:12 -05:00
catcache.c Save a few bytes by removing useless last argument to SearchCatCacheList. 2018-01-29 15:13:17 -05:00
evtcache.c Update copyright for 2018 2018-01-02 23:30:12 -05:00
inval.c Fix bugs in vacuum of shared rels, by keeping their relcache entries current. 2018-06-12 11:13:21 -07:00
lsyscache.c Add prokind column, replacing proisagg and proiswindow 2018-03-02 13:48:33 -05:00
Makefile Reorganize partitioning code 2018-04-14 21:12:14 -03:00
partcache.c Fix some ill-chosen names for globally-visible partition support functions. 2018-06-13 13:18:02 -04:00
plancache.c Add plan_cache_mode setting 2018-07-16 13:35:41 +02:00
relcache.c Cosmetic improvements for faster column addition. 2018-06-27 08:16:13 +05:30
relfilenodemap.c Fix more wrong paths in header comments 2018-07-11 17:57:04 +03:00
relmapper.c Add proper errcodes to new error messages for read() failures 2018-07-23 09:37:36 +09:00
spccache.c Update copyright for 2018 2018-01-02 23:30:12 -05:00
syscache.c Save a few bytes by removing useless last argument to SearchCatCacheList. 2018-01-29 15:13:17 -05:00
ts_cache.c Rename MemoryContextCopySetIdentifier() for clarity 2018-04-06 12:37:54 -04:00
typcache.c Fix typo in comment 2018-03-29 11:42:32 +02:00