trap.h revision 238888
143967Sache/*- 26527Sache * Copyright (c) 1991, 1993 36527Sache * The Regents of the University of California. All rights reserved. 46527Sache * 56527Sache * This code is derived from software contributed to Berkeley by 66527Sache * Kenneth Almquist. 76527Sache * 86527Sache * Redistribution and use in source and binary forms, with or without 96527Sache * modification, are permitted provided that the following conditions 106527Sache * are met: 116527Sache * 1. Redistributions of source code must retain the above copyright 126527Sache * notice, this list of conditions and the following disclaimer. 136527Sache * 2. Redistributions in binary form must reproduce the above copyright 146527Sache * notice, this list of conditions and the following disclaimer in the 156527Sache * documentation and/or other materials provided with the distribution. 166527Sache * 4. Neither the name of the University nor the names of its contributors 176527Sache * may be used to endorse or promote products derived from this software 186527Sache * without specific prior written permission. 196527Sache * 206527Sache * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 216527Sache * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 226527Sache * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 236527Sache * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 246527Sache * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 256527Sache * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 266527Sache * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 276527Sache * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 286527Sache * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 296527Sache * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 3087243Smarkm * SUCH DAMAGE. 3187243Smarkm * 3287243Smarkm * @(#)trap.h 8.3 (Berkeley) 6/5/95 33175038Simp * $FreeBSD: head/bin/sh/trap.h 238888 2012-07-29 18:04:38Z jilles $ 3418950Sache */ 356527Sache 36101867Sacheextern int pendingsigs; 376527Sacheextern int in_dotrap; 386527Sacheextern volatile sig_atomic_t gotwinch; 396527Sache 4087012Sachevoid clear_traps(void); 4116073Sphkint have_traps(void); 426527Sachevoid setsignal(int); 4343967Sachevoid ignoresig(int); 4487052Sacheint issigchldtrapped(void); 456527Sachevoid onsig(int); 466527Sachevoid dotrap(void); 476527Sachevoid setinteractive(int); 486527Sachevoid exitshell(int) __dead2; 496527Sachevoid exitshell_savedstatus(void) __dead2; 5087243Smarkm