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

fix unexpected pane closing issue with nushell #648

Merged
merged 2 commits into from
Aug 16, 2021
Merged

Conversation

tw4452852
Copy link
Contributor

@tw4452852 tw4452852 commented Aug 15, 2021

nushell doesn't create a new process group when spawning a process,
so all processes including the ones spawned by us are in the same
foreground group. So the kernel will send signal to every member of this
group.

This patch fixes this issue by creating a new foreground process group
when spawnning a new terminal pane.

Fix #615

Signed-off-by: Tw tw19881113@gmail.com

tw4452852 and others added 2 commits August 15, 2021 20:19
nushell doesn't create a new process group when spawnning a process,
so all processes including the ones spwanned by us are in the same
foreground group. So if kernel will send signal to every member of this
group.

This patch fixes this issue by creating a new foreground process group
when spawnning a new terminal pane.

Fix zellij-org#615

Signed-off-by: Tw <tw19881113@gmail.com>
@imsnif
Copy link
Member

imsnif commented Aug 16, 2021

Hey, great work on this! I added a comment to make the unsafe part a little clearer. Thanks!

@imsnif imsnif merged commit e477f3b into zellij-org:main Aug 16, 2021
@tw4452852
Copy link
Contributor Author

You're welcome.

@tw4452852 tw4452852 deleted the 615 branch August 17, 2021 01:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

interrupting a process spawned by nushell closes the pane
2 participants