summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorMartin Cracauer <cracauer@FreeBSD.org>1998-09-10 14:58:03 +0000
committerMartin Cracauer <cracauer@FreeBSD.org>1998-09-10 14:58:03 +0000
commit7418d20116d7a654380b4888b04b416fb4ab8d47 (patch)
treed1fc01b4ae35876928f70d781a47cfd6c1e91cff /bin
parent9b554f6764a03697db07bdf43ce9349c3ffdb465 (diff)
Notes
Diffstat (limited to 'bin')
-rw-r--r--bin/sh/memalloc.c3
-rw-r--r--bin/sh/trap.c15
2 files changed, 7 insertions, 11 deletions
diff --git a/bin/sh/memalloc.c b/bin/sh/memalloc.c
index 9e49b9d11027..52f933bfb929 100644
--- a/bin/sh/memalloc.c
+++ b/bin/sh/memalloc.c
@@ -33,7 +33,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: memalloc.c,v 1.4 1996/09/03 14:15:53 peter Exp $
+ * $Id: memalloc.c,v 1.4.2.1 1997/08/25 09:10:08 jkh Exp $
*/
#ifndef lint
@@ -46,6 +46,7 @@ static char const sccsid[] = "@(#)memalloc.c 8.3 (Berkeley) 5/4/95";
#include "error.h"
#include "machdep.h"
#include "mystring.h"
+#include "expand.h"
#include <stdlib.h>
#include <unistd.h>
diff --git a/bin/sh/trap.c b/bin/sh/trap.c
index 32194754856d..1d5fa488313e 100644
--- a/bin/sh/trap.c
+++ b/bin/sh/trap.c
@@ -33,7 +33,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: trap.c,v 1.4.2.3 1998/08/27 16:24:57 cracauer Exp $
+ * $Id: trap.c,v 1.4.2.4 1998/09/09 10:55:02 cracauer Exp $
*/
#ifndef lint
@@ -41,7 +41,7 @@
static char const sccsid[] = "@(#)trap.c 8.5 (Berkeley) 6/5/95";
#endif
static const char rcsid[] =
- "$Id: trap.c,v 1.4.2.3 1998/08/27 16:24:57 cracauer Exp $";
+ "$Id: trap.c,v 1.4.2.4 1998/09/09 10:55:02 cracauer Exp $";
#endif /* not lint */
#include <signal.h>
@@ -349,7 +349,6 @@ void
onsig(signo)
int signo;
{
- int i;
#ifndef BSD
signal(signo, onsig);
@@ -370,13 +369,9 @@ onsig(signo)
* If a trap is set, we need to make sure it is executed even
* when a childs blocks all signals.
*/
- for (i = 0; i < NSIG; i++) {
- if (signo == i && trap[i] != NULL &&
- ! (trap[i][0] == ':' && trap[i][1] == '\0')) {
- breakwaitcmd = 1;
- break;
- }
- }
+ if (trap[signo] != NULL &&
+ ! (trap[signo][0] == ':' && trap[signo][1] == '\0'))
+ breakwaitcmd = 1;
}