Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MSEdgeRedirect terminates UWP processes on first launch. #395

Open
1 of 2 tasks
GalaxinTM opened this issue Mar 2, 2024 · 5 comments
Open
1 of 2 tasks

MSEdgeRedirect terminates UWP processes on first launch. #395

GalaxinTM opened this issue Mar 2, 2024 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@GalaxinTM
Copy link

Preflight Checklist

  • Running microsoft-edge:https://google.com redirects successfully
  • Microsoft Edge is selected in any "How do you want to open this?" box

Install Type

Manual Update

Install Mode

Service Mode

Steps to reproduce

This isn't a bug report about the functionality of MSEdgeRedirect, but more of an odd bug I've noticed when using this program.
Whenever I launch my computer, I have a few apps set to run at startup, and some of them get terminated shortly after being launched. I launched MSEdgeRedirect manually while writing this post, which terminated some processes.

Programs that are affected:

  • ShareX
  • EarTrumpet
  • Windows Terminal

I'm running version 0.7.5.3 in Service Mode.

✔️ Expected Behavior

MSEdgeRedirect will start with other start-up programs with no issues.

❌ Actual Behavior

Some processes get terminated shortly after MSEdgeRedirect's process is started.

Microsoft Windows version

23H2 Build 22631.3155

Other Software

ShareX 15.0
Windows Terminal 1.19.10573.0
EarTrumpet 2.3.0.0

@GalaxinTM GalaxinTM added the bug Something isn't working label Mar 2, 2024
@rcmaehl rcmaehl self-assigned this Mar 2, 2024
@riverar
Copy link

riverar commented Mar 2, 2024

EarTrumpet dev here, can't reproduce this here. Do you have any of these selected?

image

rcmaehl added a commit that referenced this issue Mar 3, 2024
@rcmaehl
Copy link
Owner

rcmaehl commented Mar 3, 2024

EarTrumpet dev here, can't reproduce this here. Do you have any of these selected?

-snip-

Not sure how they have the processes running at startup but they're likely spawning via SIHost and that's likely the issue. It's an issue of a race condition that I probably wouldn't have if I wasn't using an interpreted language.

One day I'll figure out how exactly a C# app should have it's files laid out, how to make a proper csproj file, and the whole shebang that goes with C# coding that isn't coding itself and most if not all of service mode's issues will go away.

Regardless 334780c seems to work. I'll have to test the patch on a slower system for its reliability, and see if it handles anything unsafely.

@GalaxinTM
Copy link
Author

EarTrumpet dev here, can't reproduce this here. Do you have any of these selected?

-image1-

I currently have these options selected.
image

Not sure how they have the processes running at startup but they're likely spawning via SIHost and that's likely the issue.

The same issue happens as well when I launch MSEdgeRedirect manually. It seems like it doesn't have anything to do with the start-up process.
Upon further analysis on trying to reproduce this bug, I've found that any UWP program will get terminated if MSEdgeRedirect launches for the first time. Once MSEdgeRedirect launches for the first time, it terminates all UWP programs present, and other subsequent launches of MSEdgeRedirect won't terminate UWP programs.

Below I've attached a video of said issue happening, and a screenshot of my Task Manager's start-up list.

image

msedgeredirect.bugreport.mp4

@GalaxinTM GalaxinTM changed the title MSEdgeRedirect terminates random processes. MSEdgeRedirect terminates UWP processes on first launch. Mar 3, 2024
@rcmaehl
Copy link
Owner

rcmaehl commented Mar 3, 2024

If you could, launch ProcessExplorer instead of ProcessHacker and ensure it's in Treeview

image

@GalaxinTM
Copy link
Author

I'm able to provide both before and after snapshots of ProcessExplorer (same setup, didn't change anything)
I noticed that the entire sihost.exe tree got terminated with its child processes.
Secure System.txt
Secure System_old.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants