浏览代码

Bug 1485: Do not update last access time of uploaded files with SFTP protocol to avoid problems with servers that do not support it

https://winscp.net/tracker/1485

Source commit: cf53aea511fde8e26689f02a3312570c132ee263
Martin Prikryl 9 年之前
父节点
当前提交
d3f7ab8301
共有 1 个文件被更改,包括 3 次插入4 次删除
  1. 3 4
      source/core/SftpFileSystem.cpp

+ 3 - 4
source/core/SftpFileSystem.cpp

@@ -4576,11 +4576,11 @@ void __fastcall TSFTPFileSystem::SFTPSource(const UnicodeString FileName,
   OpenParams.OverwriteMode = omOverwrite;
 
   HANDLE File;
-  __int64 MTime, ATime;
+  __int64 MTime;
   __int64 Size;
 
   FTerminal->OpenLocalFile(FileName, GENERIC_READ, &OpenParams.LocalFileAttrs,
-    &File, NULL, &MTime, &ATime, &Size);
+    &File, NULL, &MTime, NULL, &Size);
 
   bool Dir = FLAGSET(OpenParams.LocalFileAttrs, faDirectory);
 
@@ -4810,8 +4810,7 @@ void __fastcall TSFTPFileSystem::SFTPSource(const UnicodeString FileName,
         PropertiesRequest.AddProperties(
           SetRights ? &RightsNumber : NULL, NULL, NULL,
           CopyParam->PreserveTime ? &MTime : NULL,
-          CopyParam->PreserveTime ? &ATime : NULL,
-          NULL, false, FVersion, FUtfStrings);
+          NULL, NULL, false, FVersion, FUtfStrings);
       }
 
       try