From: | Andrew Dunstan <andrew(at)dunslane(dot)net> |
---|---|
To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
Subject: | pgsql: Fix lstat() for broken junction points on Windows. |
Date: | 2024-11-07 23:19:39 |
Message-ID: | [email protected] |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Fix lstat() for broken junction points on Windows.
When using junction points to emulate symlinks on Windows, one edge case
was not handled correctly by commit c5cb8f3b: if a junction point is
broken (pointing to a non-existent path), we'd report ENOENT. This
doesn't break any known use case, but was noticed while developing a
test suite for these functions and is fixed here for completeness.
Also add translation ERROR_CANT_RESOLVE_FILENAME -> ENOENT, as that is
one of the errors Windows can report for some kinds of broken paths.
Discussion: https://postgr.es/m/CA%2BhUKG%2BajSQ_8eu2AogTncOnZ5me2D-Cn66iN_-wZnRjLN%2Bicg%40mail.gmail.com
(cherry picked from commit 387803d81d6256fcb60b9192bb5b00042442b4e3)
Author: Thomas Munro <tmunro(at)postgresql(dot)org>
Author: Alexandra Wang <alexandra(dot)wang(dot)oss(at)gmail(dot)com>
Branch
------
REL_14_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/8a5e4982f9c536fafa4ae9b7c331ee656ded2fe5
Author: Thomas Munro <tmunro(at)postgresql(dot)org>
Modified Files
--------------
src/port/win32error.c | 6 ++++++
src/port/win32stat.c | 27 ++++++++++++++++++++++-----
2 files changed, 28 insertions(+), 5 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Richard Guo | 2024-11-08 02:25:45 | pgsql: Fix inconsistent RestrictInfo serial numbers |
Previous Message | Andrew Dunstan | 2024-11-07 23:19:38 | pgsql: Provide lstat() for Windows. |