瀏覽代碼

Bug 1672: Timezone autodetection failed if timestamp of file cannot be retrieved

https://winscp.net/tracker/1672

Source commit: 8ffeb8bee098a90266ff674f47891073a196693d
Martin Prikryl 7 年之前
父節點
當前提交
329a0a6037
共有 1 個文件被更改,包括 7 次插入0 次删除
  1. 7 0
      source/core/FtpFileSystem.cpp

+ 7 - 0
source/core/FtpFileSystem.cpp

@@ -2094,6 +2094,13 @@ void __fastcall TFTPFileSystem::AutoDetectTimeDifference(TRemoteFileList * FileL
             FORMAT(L"Not using file %s to detect timezone difference as it has the timestamp in the future [%s]",
               (File->FullFileName, StandardTimestamp(UtcModification))));
         }
+        // "SecureLink FTP Proxy" succeeds CWD for a file, so we never get a timestamp here
+        else if (UtcModification == TDateTime())
+        {
+          FTerminal->LogEvent(
+            FORMAT(L"Not using file %s to detect timezone difference as its timestamp was not resolved",
+              (File->FullFileName)));
+        }
         else
         {
           FDetectTimeDifference = false;