View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001833 | Far Manager | FindFiles | public | 2011-07-11 14:41 | 2011-08-25 08:07 |
Reporter | Maximus | Assigned To | DrKnS | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | 3.0 | ||||
Fixed in Version | 3.0 | ||||
Summary | 0001833: Поиск файлов - не ThreadSafe | ||||
Description | Во время выполнения в фоновом потоке > Far.exe!ArchiveSearch(void * hDlg, const wchar_t * ArcName) Line 2425 C++ Far.exe!DoScanTree(void * hDlg, UnicodeString & strRoot) Line 2635 + 0x15 bytes C++ Far.exe!DoPrepareFileList(void * hDlg) Line 2830 + 0xd bytes C++ Far.exe!ThreadRoutine(void * Param) Line 2887 + 0x33 bytes C++ в главном потоке продолжает крутиться ProcessMainLoop > Far.exe!console::ReadInput(_INPUT_RECORD * Buffer, unsigned long Length, unsigned long & NumberOfEventsRead) Line 274 + 0x1d bytes C++ Far.exe!GetInputRecord(_INPUT_RECORD * rec, bool ExcludeMacro, bool ProcessMouse, bool AllowSynchro) Line 1137 + 0x14 bytes C++ Far.exe!Manager::ProcessMainLoop() Line 702 + 0x12 bytes C++ Far.exe!Manager::ExecuteModal(Frame * Executed) Line 338 C++ Far.exe!Dialog::Process() Line 4317 C++ Far.exe!FindFilesProcess(Vars & v) Line 3012 C++ Far.exe!FindFiles::FindFiles() Line 3425 + 0x9 bytes C++ Far.exe!FilePanels::ProcessKey(int Key) Line 672 C++ что приводит к печальным последствиям... | ||||
Tags | No tags attached. | ||||
Build | 2167 | ||||
|
FindFile.110721.diff (1,121 bytes)
Index: findfile.cpp =================================================================== --- findfile.cpp (revision 6465) +++ findfile.cpp (working copy) @@ -1538,6 +1538,7 @@ INT_PTR WINAPI FindDlgProc(HANDLE hDlg, int Msg, int Param1, void* Param2) { + CriticalSectionLock Lock(PluginCS); Vars* v = reinterpret_cast<Vars*>(SendDlgMessage(hDlg, DM_GETDLGDATA, 0, 0)); Dialog* Dlg=static_cast<Dialog*>(hDlg); VMenu *ListBox=Dlg->GetAllItem()[FD_LISTBOX]->ListPtr; @@ -2422,12 +2423,17 @@ int SavePluginsOutput=DisablePluginsOutput; DisablePluginsOutput=TRUE; string strArcName = ArcName; - HANDLE hArc=CtrlObject->Plugins.OpenFilePlugin(strArcName, OPM_FIND, OFP_SEARCH); + HANDLE hArc; + { + CriticalSectionLock Lock(PluginCS); + hArc = CtrlObject->Plugins.OpenFilePlugin(strArcName, OPM_FIND, OFP_SEARCH); + } DisablePluginsOutput=SavePluginsOutput; if (hArc==(HANDLE)-2) { - StopEvent.Set(); + // �� ������������ �����, ���� ���������� �������� �� ��������� ������ ��� + //StopEvent.Set(); _ALGO(SysLog(L"return: hArc==(HANDLE)-2")); return; } |
|
Ну, хотя бы так |
Date Modified | Username | Field | Change |
---|---|---|---|
2011-07-11 14:41 | Maximus | New Issue | |
2011-07-21 21:22 | Maximus | File Added: FindFile.110721.diff | |
2011-07-21 21:23 | Maximus | Note Added: 0007292 | |
2011-08-25 08:07 | DrKnS | Build | => 2167 |
2011-08-25 08:07 | DrKnS | Status | new => closed |
2011-08-25 08:07 | DrKnS | Assigned To | => DrKnS |
2011-08-25 08:07 | DrKnS | Resolution | open => fixed |
2011-08-25 08:07 | DrKnS | Fixed in Version | => 3.0 |