ksh: Drop support for ISC UNIX

This commit is contained in:
kamil 2017-06-22 23:47:29 +00:00
parent eed5a31e9b
commit 237b342911
3 changed files with 7 additions and 23 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: config.h,v 1.29 2017/06/22 23:38:49 kamil Exp $ */
/* $NetBSD: config.h,v 1.30 2017/06/22 23:47:29 kamil Exp $ */
/* config.h. Generated automatically by configure. */
/* config.h.in. Generated automatically from configure.in by autoheader. */
@ -144,9 +144,6 @@
/* Define if the pgrp of setpgrp() can't be the pid of a zombie process */
/* #undef NEED_PGRP_SYNC */
/* Define if you arg running ISC unix */
/* #undef OS_ISC */
/* Define if you have a POSIX.1 compatible <sys/wait.h> */
#define POSIX_SYS_WAIT 1

View File

@ -1,4 +1,4 @@
/* $NetBSD: exec.c,v 1.18 2017/06/22 14:20:46 kamil Exp $ */
/* $NetBSD: exec.c,v 1.19 2017/06/22 23:47:29 kamil Exp $ */
/*
* execute command tree
@ -6,7 +6,7 @@
#include <sys/cdefs.h>
#ifndef lint
__RCSID("$NetBSD: exec.c,v 1.18 2017/06/22 14:20:46 kamil Exp $");
__RCSID("$NetBSD: exec.c,v 1.19 2017/06/22 23:47:29 kamil Exp $");
#endif
@ -420,7 +420,7 @@ execute(t, flags)
#endif
restoresigs();
cleanup_proc_env();
ksh_execve(t->str, t->args, ap, flags);
execve(t->str, t->args, ap);
if (errno == ENOEXEC)
scriptexec(t, ap);
else
@ -813,7 +813,7 @@ scriptexec(tp, ap)
#endif /* SHARPBANG */
*tp->args = shellv;
ksh_execve(tp->args[0], tp->args, ap, 0);
execve(tp->args[0], tp->args, ap);
/* report both the program that was run and the bogus shell */
errorf("%s: %s: %s", tp->str, shellv, strerror(errno));

View File

@ -1,10 +1,10 @@
/* $NetBSD: sh.h,v 1.24 2017/06/22 23:42:35 kamil Exp $ */
/* $NetBSD: sh.h,v 1.25 2017/06/22 23:47:29 kamil Exp $ */
/*
* Public Domain Bourne/Korn shell
*/
/* $Id: sh.h,v 1.24 2017/06/22 23:42:35 kamil Exp $ */
/* $Id: sh.h,v 1.25 2017/06/22 23:47:29 kamil Exp $ */
#include "config.h" /* system and option configuration info */
@ -108,19 +108,6 @@ typedef RETSIGTYPE (*handler_t) ARGS((int)); /* signal handler */
# define killpg(p, s) kill(-(p), (s))
#endif /* !HAVE_KILLPG */
/* Special cases for execve(2) */
# if defined(OS_ISC) && defined(_POSIX_SOURCE)
/* Kludge for ISC 3.2 (and other versions?) so programs will run correctly. */
# define ksh_execve(p, av, ev, flags) \
do { \
__setostype(0); \
execve(p, av, ev); \
__setostype(1); \
} while (0)
# else /* OS_ISC && _POSIX */
# define ksh_execve(p, av, ev, flags) execve(p, av, ev)
# endif /* OS_ISC && _POSIX */
/* this is a hang-over from older versions of the os2 port */
#define ksh_dupbase(fd, base) fcntl(fd, F_DUPFD, base)