File: sigig_bsd.c

package info (click to toggle)
clif 0.93-9.1
  • links: PTS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 4,228 kB
  • sloc: ansic: 31,464; yacc: 5,067; lex: 819; makefile: 383; sh: 48
file content (27 lines) | stat: -rw-r--r-- 435 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/*
 * sigig_bsd.c
 *
 * Ignores interrupts in a fork-ed process.
 * It is used from rw.c file.
 */

#include <signal.h>


struct sigvec vec_fork,ovec_fork;

#ifndef PROTO
#if defined (USE_PROTOTYPES) ? USE_PROTOTYPES : defined(__STDC__)
#define PROTO(ARGS) ARGS
#else
#define PROTO(ARGS) ()
#endif 
#endif

void mysigignore PROTO((void));

void mysigignore()
{
 vec_fork.sv_handler = SIG_IGN;
 sigvec(SIGINT, &vec_fork, &ovec_fork);
}