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

make script(1) and lib/pty-session.c more portable #2054

Open
karelzak opened this issue Feb 3, 2023 · 0 comments
Open

make script(1) and lib/pty-session.c more portable #2054

karelzak opened this issue Feb 3, 2023 · 0 comments
Labels
TODO We going to think about it ;-)

Comments

@karelzak
Copy link
Collaborator

karelzak commented Feb 3, 2023

The lib/pty-session.c code uses signalfd to deal with signals. It's an excellent and very reliable solution, but it's not portable to enough for Debian (due to kFreeBSD and Hurd). See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=807071 for more details.

It would be nice to #ifdef signal FD and as fallback use sigaction() with SA_SIGINFO and in handle_signal() use data from siginfo_t (for signalfd it uses struct signalfd_siginfo).

Note that signalfd should be the preferred solution for Linux.

@karelzak karelzak added the TODO We going to think about it ;-) label Feb 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TODO We going to think about it ;-)
Projects
None yet
Development

No branches or pull requests

2 participants
@karelzak and others