Module Name: src
Committed By: kamil
Date: Thu Jun 22 23:47:29 UTC 2017
Modified Files:
src/bin/ksh: config.h exec.c sh.h
Log Message:
ksh: Drop support for ISC UNIX
To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/bin/ksh/config.h
cvs rdiff -u -r1.18 -r1.19 src/bin/ksh/exec.c
cvs rdiff -u -r1.24 -r1.25 src/bin/ksh/sh.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/bin/ksh/config.h
diff -u src/bin/ksh/config.h:1.29 src/bin/ksh/config.h:1.30
--- src/bin/ksh/config.h:1.29 Thu Jun 22 23:38:49 2017
+++ src/bin/ksh/config.h Thu Jun 22 23:47:29 2017
@@ -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
Index: src/bin/ksh/exec.c
diff -u src/bin/ksh/exec.c:1.18 src/bin/ksh/exec.c:1.19
--- src/bin/ksh/exec.c:1.18 Thu Jun 22 14:20:46 2017
+++ src/bin/ksh/exec.c Thu Jun 22 23:47:29 2017
@@ -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));
Index: src/bin/ksh/sh.h
diff -u src/bin/ksh/sh.h:1.24 src/bin/ksh/sh.h:1.25
--- src/bin/ksh/sh.h:1.24 Thu Jun 22 23:42:35 2017
+++ src/bin/ksh/sh.h Thu Jun 22 23:47:29 2017
@@ -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((in
# 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)