SIG(3)

πŸ“¦ version 93vu, in opensuse-leap 16.0

πŸ’– SIG(3) β€” Library Functions Manual πŸ’–

okay bestie, welcome to the Library Functions Manual page for SIG(3) β€” it's shorter than my attention span but lowkey iconic. Let's get into it. ✨


🌸 NAME 🌸

sig β€” signal interface routines. That's the whole name, no cap. πŸ’…

✨ SYNOPSIS ✨

#include <ast.h> #include <sig.h>

int sigunblock(int sig); int sigcritical(int op);

πŸ¦‹ DESCRIPTION πŸ¦‹

So sigunblock is the lil rescue move: you call it to unblock the signal sig from inside a handler that's currently servicing sig. Basically it's saying "okay bestie, you can come through now" while you're already handling that exact signal. πŸ’–

sigcritical is the bouncer for a critical region covering SIGINT, SIGQUIT, and SIGHUP. The op value changes what it does:

  • op > 0 β€” pushes the region. Critical region goes brrr. πŸ”₯
  • op == 0 β€” pops the region. Bye, region. πŸ‘‹
  • op < 0 β€” returns non-zero if any signals are being held in the current critical region. It's giving "are we holding signals rn?" energy. πŸ‘€

Signal critical regions may be nested, so you can stack them like cute lil bracelets. πŸŽ€ The current critical region level is returned, and -1 comes back on error. Periodt.

🌈 SEE ALSO 🌈

  • signal(2) β€” go read that one next, bestie. 🫢

mwah πŸ’‹ β€” that's the whole SIG(3) page from the Library Functions Manual. No version or date is listed on this copy, so the footer vibes are just "Library Functions Manual, SIG(3), and nothing else." fr fr. πŸ¦‹

πŸ“¦ where this page comes from