Skip to content

Commit 765786a

Browse files
fix: also check another place
1 parent 45d8464 commit 765786a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/shell/script/binding_types_com.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,8 @@ auto GetDesktopIShellBrowser() {
105105
auto spShellWindows = CComPtr<IShellWindows>();
106106
spShellWindows.CoCreateInstance(CLSID_ShellWindows);
107107

108+
if (!spShellWindows)
109+
return std::optional<std::pair<HWND, CComPtr<IShellBrowser>>>();
108110
CComVariant vtLoc(CSIDL_DESKTOP);
109111
CComVariant vtEmpty;
110112

0 commit comments

Comments
 (0)