summaryrefslogtreecommitdiff
path: root/sal/util
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2018-09-07 17:11:48 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2018-09-27 16:43:48 +0200
commitc9343988204ee3e9889f3cc833adbbaca83e53e6 (patch)
treebe94bfad127deb256a55e957b3a82268e3ef97b9 /sal/util
parentbfd2393ca7247aae1b09e661610a5f750b6e06fa (diff)
tdf#119238: keep replaced file's identity when renaming docfile
Regression from 2157a3536f97ff5ae7c82611a801fef7e3708983 sfx2 store: try rename before copying Rename is cheaper then copying the content over manually, so try that first. On Windows, we need to keep the file's dentity, including metadata (e.g., creation time, which is kept in FS). WinAPI has ReplaceFileW specifically for this, and it keeps ACLs of the original file, and otherwise makes the changed file not a separate entry, but updated old file from system's PoV. Eventually, we could try to restructure creating backup copies (e.g., for documents when configured so) to take advantage of this function being able to do that. Change-Id: I6001a2a3af5e10bc010f5ef129f4bb6f83ee1581 Reviewed-on: https://gerrit.libreoffice.org/60163 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Jenkins
Diffstat (limited to 'sal/util')
-rw-r--r--sal/util/sal.map5
1 files changed, 5 insertions, 0 deletions
diff --git a/sal/util/sal.map b/sal/util/sal.map
index 07150ab0340d..9292d50ca423 100644
--- a/sal/util/sal.map
+++ b/sal/util/sal.map
@@ -700,6 +700,11 @@ LIBO_UDK_5.3 { # symbols available in >= LibO 5.3
rtl_uString_newReplaceFirstUtf16LUtf16L;
} LIBO_UDK_5.2;
+LIBO_UDK_6.2 { # symbols available in >= LibO 6.2
+ global:
+ osl_replaceFile;
+} LIBO_UDK_5.3;
+
PRIVATE_1.0 {
global:
osl_detail_ObjectRegistry_storeAddresses;