浏览代码

Bug 1684: Failure when canceling session reconnect (4th)

https://winscp.net/tracker/1684

Source commit: efc27f1f2e6de5401f2074b8a48e0da713418c5d
Martin Prikryl 7 年之前
父节点
当前提交
f1624975f0
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      source/components/UnixDriveView.cpp

+ 4 - 1
source/components/UnixDriveView.cpp

@@ -79,7 +79,10 @@ void __fastcall TCustomUnixDriveView::SetTerminal(TTerminal * value)
     FTerminal = value;
     Items->Clear();
     #ifndef DESIGN_ONLY
-    if (FTerminal != NULL)
+    // If terminal is not active initially, we will never load fixed paths, when it become active.
+    // But actually terminal is not active here, only when we are replacing an abandoned terminal
+    // with a dummy one (which will never become active)
+    if ((FTerminal != NULL) && FTerminal->Active)
     {
       TStrings * FixedPaths = FTerminal->FixedPaths;
       if (FixedPaths != NULL)