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

in case of $? take value from shell->exit_status #29

Merged
merged 2 commits into from
Jul 17, 2024

Conversation

dmytro-mz
Copy link
Collaborator

No description provided.

@dmytro-mz dmytro-mz linked an issue Jul 10, 2024 that may be closed by this pull request
@@ -25,8 +25,8 @@ void non_interactive_signal_handlers(void)

sigemptyset(&sa_int.sa_mask);
sigemptyset(&sa_quit.sa_mask);
sigaddset(&sa_int.sa_mask, SIGINT);
sigaddset(&sa_quit.sa_mask, SIGQUIT);
sigaddset(&sa_int.sa_mask, SIGQUIT);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it intentional or the code base it not updated?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it was intendant. the same signal is by default do not interrupt processing of previous signal, but it's queued. So I thought the idea is to not let SIGINT interrupt action caused by SIGQUIT
should i roll it back?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually sigaddset is not needed at all since sigaction is used. I shouldn't make any difference with or without. So, you can remove them totally.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@dmytro-mz dmytro-mz merged commit 6b551ad into master Jul 17, 2024
1 check failed
@dmytro-mz dmytro-mz deleted the 8-return-value-of-a-process branch July 17, 2024 19:24
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.

Return value of a process
2 participants