|
@@ -1921,7 +1921,12 @@ __fastcall TSFTPFileSystem::TSFTPFileSystem(TTerminal * ATerminal,
|
|
|
__fastcall TSFTPFileSystem::~TSFTPFileSystem()
|
|
|
{
|
|
|
delete FSupport;
|
|
|
- NoPacketReservations();
|
|
|
+ // After closing, we can only possibly have "discard" reservations of the not-read responses to the last requests
|
|
|
+ // (typically to SSH_FXP_CLOSE)
|
|
|
+ for (int i = 0; i < FPacketReservations->Count; i++)
|
|
|
+ {
|
|
|
+ DebugAssert(FPacketReservations->Items[i] == NULL);
|
|
|
+ }
|
|
|
delete FPacketReservations;
|
|
|
delete FFixedPaths;
|
|
|
delete FSecureShell;
|
|
@@ -1929,22 +1934,11 @@ __fastcall TSFTPFileSystem::~TSFTPFileSystem()
|
|
|
//---------------------------------------------------------------------------
|
|
|
void __fastcall TSFTPFileSystem::Open()
|
|
|
{
|
|
|
- NoPacketReservations();
|
|
|
- ResetConnection();
|
|
|
// this is used for reconnects only
|
|
|
+ ResetConnection();
|
|
|
FSecureShell->Open();
|
|
|
}
|
|
|
//---------------------------------------------------------------------------
|
|
|
-void TSFTPFileSystem::NoPacketReservations()
|
|
|
-{
|
|
|
- // After closing, we can only possibly have "discard" reservations of the not-read responses to the last requests
|
|
|
- // (typocally to SSH_FXP_CLOSE)
|
|
|
- for (int i = 0; i < FPacketReservations->Count; i++)
|
|
|
- {
|
|
|
- DebugAssert(FPacketReservations->Items[i] == NULL);
|
|
|
- }
|
|
|
-}
|
|
|
-//---------------------------------------------------------------------------
|
|
|
void __fastcall TSFTPFileSystem::Close()
|
|
|
{
|
|
|
FSecureShell->Close();
|