Skip to content

Commit 2130047

Browse files
committed
Prevent potential Explorer crash
Fixes #1523
1 parent bcc76dd commit 2130047

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Src/ClassicExplorer/ExplorerBHO.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ LRESULT CALLBACK CExplorerBHO::SubclassTreeParentProc( HWND hWnd, UINT uMsg, WPA
6464
// - change the tree styles to achieve different looks
6565
LRESULT CALLBACK CExplorerBHO::SubclassTreeProc( HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam, UINT_PTR uIdSubclass, DWORD_PTR dwRefData )
6666
{
67+
if (GetTlsData()->bho == NULL)
68+
return DefSubclassProc(hWnd, uMsg, wParam, lParam);
69+
6770
if (uMsg==TVM_ENSUREVISIBLE && (dwRefData&1))
6871
{
6972
// HACK! there is a bug in Win7 Explorer and when the selected folder is expanded for the first time it sends TVM_ENSUREVISIBLE for

0 commit comments

Comments
 (0)