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

ignore SIGPIPE to handle broken pipes explicitly #1397

Merged
merged 1 commit into from
Apr 25, 2024

Conversation

jluebbe
Copy link
Member

@jluebbe jluebbe commented Apr 25, 2024

Glib already sets SIGPIPE to ignore when using gsocket and will do the same for gsubprocess from 2.82 as well [1]. As we want to handle all broken pipe errors explicitly, we should do it globally.

We add the call in r_context_conf instead of in main() to catch the relevant tests as well. For the nbd helper (which doesn't use a context), we do it on startup.

[1] https://gitlab.gnome.org/GNOME/glib/-/merge_requests/3991

Glib already sets SIGPIPE to ignore when using gsocket and will do the
same for gsubprocess from 2.82 as well [1]. As we want to handle all
broken pipe errors explicitly, we should do it globally.

We add the call in r_context_conf instead of in main() to catch the
relevant tests as well. For the nbd helper (which doesn't use a
context), we do it on startup.

[1] https://gitlab.gnome.org/GNOME/glib/-/merge_requests/3991

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
@jluebbe jluebbe merged commit dda21d6 into rauc:master Apr 25, 2024
16 checks passed
@jluebbe jluebbe deleted the ignore-sigpipe branch April 25, 2024 10:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants