The tdf#150118 fix used AccessCheck to check write permissions when
FILE_ATTRIBUTE_READONLY is not set. However, AccessCheck uses a local
impersonation token which does not reflect the network credentials
used by the SMB redirector, causing files on remote drives to be
incorrectly marked as read-only.
Skip the AccessCheck logic for remote drives by detecting UNC paths
(\\server\share\...) and mapped network drives (via GetDriveTypeW
returning DRIVE_REMOTE).
regression after: 1b5d039d8b
Change-Id: I7f1514db89655e8607f64da3d62e8e29c23105f4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/199997
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
Tested-by: Balazs Varga <balazs.varga@collabora.com>
System Abstraction Layer (SAL)
System abstraction layer; rtl, osl and sal
rtl:
Platform independent strings
osl:
platform specific stuff, threads, dynamic loading, process, ipc, etc
Exports only C API and some inline-methods (only C++ API).