Skip to content

Commit 950cf77

Browse files
committed
feat(bootstrapper): kill prefix on final studio process
1 parent 6b8ab60 commit 950cf77

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

cmd/vinegar/bootstrapper_run.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,14 @@ func (b *bootstrapper) execute(args ...string) error {
6969
b.procs = slices.DeleteFunc(b.procs, func(p *os.Process) bool {
7070
return p == cmd.Process
7171
})
72+
if len(b.procs) > 0 {
73+
return
74+
}
75+
76+
// Workaround any other stray processes holding Wine up
77+
// such as WebView
78+
slog.Warn("No more processes left, killing Wineprefix")
79+
b.pfx.Kill()
7280
}()
7381

7482
gtkutil.IdleAdd(func() {

0 commit comments

Comments
 (0)