Skip to content

Commit

Permalink
workaround crash in far 3.0.5242+.
Browse files Browse the repository at this point in the history
  • Loading branch information
zg0 committed Aug 1, 2018
1 parent 145e207 commit 0d4359d
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/NetBox/FarPlugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1889,7 +1889,13 @@ void TCustomFarFileSystem::GetOpenPanelInfo(struct OpenPanelInfo *Info)
// FAR WORKAROUND
// if plugin is closed from ProcessPanelEvent(FE_IDLE), is does not close,
// so we close it here on the very next opportunity
ClosePanel();
static bool InsideClose=false;
if (!InsideClose)
{
InsideClose = true;
ClosePanel();
InsideClose = false;
}
}
else
{
Expand Down Expand Up @@ -2988,4 +2994,3 @@ uintptr_t TGlobalFunctions::MoreMessageDialog(UnicodeString Message, TStrings *M
TWinSCPPlugin *WinSCPPlugin = dyn_cast<TWinSCPPlugin>(FarPlugin);
return WinSCPPlugin->MoreMessageDialog(Message, MoreMessages, Type, Answers, Params);
}

0 comments on commit 0d4359d

Please sign in to comment.