[PR #8977] [MERGED] Fix crash in explorer background context menu logic #27353

Open
opened 2026-01-31 09:21:29 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/8977
Author: @hereafter
Created: 1/31/2021
Status: ✅ Merged
Merged: 2/1/2021
Merged by: @undefined

Base: main ← Head: dev/hereafter/context-menu-patch


📝 Commits (10+)

  • 60a612c make open terminal here context menu for directory background
  • cf274cc fix missing new line
  • a129ff1 code formating
  • 9abb707 spell checker
  • 443ac08 Update src/cascadia/ShellExtension/OpenTerminalHere.cpp
  • 3469721 Update src/cascadia/ShellExtension/OpenTerminalHere.h
  • 978392d bug fix private function rename
  • 03a91ff trivial
  • 8f73d59 revert vcpkg settings
  • 2e76c95 move user.lib linking to the project setting

📊 Changes

1 file changed (+14 additions, -1 deletions)

View changed files

📝 src/cascadia/ShellExtension/OpenTerminalHere.cpp (+14 -1)

📄 Description

Fix a bug brought in with PR: #8638

see,
#8936
#8638

With the help from @nc-x, the issue is reproduced and fixed by this patch.

CLSCTX_IN_PROCESS is not good enough for all cases to create IShellWindows interface.
Put a CLSCTX_ALL fixes the issue.

Another debugging warning dialogs for reusing not null com_ptr in the loop is fixed too.
(This was shown in debug builds only)


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/8977 **Author:** [@hereafter](https://github.com/hereafter) **Created:** 1/31/2021 **Status:** ✅ Merged **Merged:** 2/1/2021 **Merged by:** [@undefined](undefined) **Base:** `main` ← **Head:** `dev/hereafter/context-menu-patch` --- ### 📝 Commits (10+) - [`60a612c`](https://github.com/microsoft/terminal/commit/60a612cbe1bdbbe382244049eed08b29511aab55) make open terminal here context menu for directory background - [`cf274cc`](https://github.com/microsoft/terminal/commit/cf274cc74feb4176987f8a1042da3307891f58b0) fix missing new line - [`a129ff1`](https://github.com/microsoft/terminal/commit/a129ff14ec985d6b7bf09e296a831c955d41040b) code formating - [`9abb707`](https://github.com/microsoft/terminal/commit/9abb7078c08ae2eaa4f05230a2aeb50fd102503b) spell checker - [`443ac08`](https://github.com/microsoft/terminal/commit/443ac08bc0c463901a509a78e0833e35f4e02bae) Update src/cascadia/ShellExtension/OpenTerminalHere.cpp - [`3469721`](https://github.com/microsoft/terminal/commit/3469721aa95e06fcd331b2be0894762e86ac9e5d) Update src/cascadia/ShellExtension/OpenTerminalHere.h - [`978392d`](https://github.com/microsoft/terminal/commit/978392df085f928195c9af48a64849346fabe0f0) bug fix private function rename - [`03a91ff`](https://github.com/microsoft/terminal/commit/03a91ff79d844468acebd9ec74b91a1f3efb49ef) trivial - [`8f73d59`](https://github.com/microsoft/terminal/commit/8f73d59922fbcec2fb377b75eaf4b027337a4056) revert vcpkg settings - [`2e76c95`](https://github.com/microsoft/terminal/commit/2e76c959413f7d4d2546d4a4845c0df30685fa26) move user.lib linking to the project setting ### 📊 Changes **1 file changed** (+14 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/ShellExtension/OpenTerminalHere.cpp` (+14 -1) </details> ### 📄 Description Fix a bug brought in with PR: #8638 see, #8936 #8638 * [x] Closes #8936 * [x] CLA signed * [x] Tests passed With the help from @nc-x, the issue is reproduced and fixed by this patch. CLSCTX_IN_PROCESS is not good enough for all cases to create IShellWindows interface. Put a CLSCTX_ALL fixes the issue. Another debugging warning dialogs for reusing not null com_ptr in the loop is fixed too. (This was shown in debug builds only) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:21:29 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#27353