postgresql/src
Tom Lane 5b22ff764b Teach pg_ls_dir_files() to ignore ENOENT failures from stat().
Buildfarm experience shows that this function can fail with ENOENT
if some other process unlinks a file between when we read the directory
entry and when we try to stat() it.  The problem is old but we had
not noticed it until 085b6b667 added regression test coverage.

To fix, just ignore ENOENT failures.  There is one other case that
this might hide: a symlink that points to nowhere.  That seems okay
though, at least better than erroring.

Back-patch to v10 where this function was added, since the regression
test cases were too.

Discussion: https://postgr.es/m/20200308173103.GC1357@telsasoft.com
2020-03-31 12:57:55 -04:00
..
backend Teach pg_ls_dir_files() to ignore ENOENT failures from stat(). 2020-03-31 12:57:55 -04:00
bin pg_upgrade: make get_major_server_version() err msg consistent 2020-03-19 15:20:55 -04:00
common Fix typo 2020-02-19 21:09:39 +01:00
fe_utils Fix translation of special characters in psql's LaTeX output modes. 2018-11-26 17:32:51 -05:00
include Revert "Skip WAL for new relfilenodes, under wal_level=minimal." 2020-03-22 09:24:13 -07:00
interfaces Stamp 11.7. 2020-02-10 17:17:28 -05:00
makefiles Select CFLAGS_SL at configure time, not in platform-specific Makefiles. 2019-10-21 12:32:36 -04:00
pl Ensure that plpgsql cleans up cleanly during parallel-worker exit. 2020-03-26 18:06:55 -04:00
port Be more careful about extracting encoding from locale strings on Windows. 2020-03-30 11:14:58 -04:00
template Select CFLAGS_SL at configure time, not in platform-specific Makefiles. 2019-10-21 12:32:36 -04:00
test Add regression tests for constraint errors in partitioned tables. 2020-03-23 14:52:18 -07:00
timezone Update time zone data files to tzdata release 2019c. 2019-09-20 19:54:00 -04:00
tools Turn off deprecated bison warnings under MSVC 2020-03-20 14:02:15 -04:00
tutorial Update copyright for 2018 2018-01-02 23:30:12 -05:00
.gitignore Convert cvsignore to gitignore, and add .gitignore for build targets. 2010-09-22 12:57:04 +02:00
DEVELOPERS Replace a couple of references to files that no longer exist in the source 2009-05-04 08:08:47 +00:00
Makefile Fix partial-build problems introduced by having more generated headers. 2018-04-09 16:42:10 -04:00
Makefile.global.in Select CFLAGS_SL at configure time, not in platform-specific Makefiles. 2019-10-21 12:32:36 -04:00
Makefile.shlib Ensure static libraries have correct mod time even if ranlib messes it up. 2018-11-29 15:53:44 -05:00
nls-global.mk nls-global.mk: search build dir for source files, too 2016-06-07 18:55:18 -04:00