integrate latest changes from oksh: Wed Sep 4 15:49:19 2013 UTC by millert

Add a proper suspend builtin that saves/restores the tty and pgrp
as needed instead of an alias that just sends SIGSTOP.  Login shells
may be suspended if they are not running in an orphan process group.
This commit is contained in:
tg
2013-09-10 17:33:04 +00:00
parent 8352fc78d3
commit 2e7509548a
8 changed files with 112 additions and 29 deletions

5
main.c
View File

@ -1,4 +1,4 @@
/* $OpenBSD: main.c,v 1.52 2013/06/15 17:25:19 millert Exp $ */
/* $OpenBSD: main.c,v 1.53 2013/09/04 15:49:19 millert Exp $ */
/* $OpenBSD: tty.c,v 1.9 2006/03/14 22:08:01 deraadt Exp $ */
/* $OpenBSD: io.c,v 1.22 2006/03/17 16:30:13 millert Exp $ */
/* $OpenBSD: table.c,v 1.15 2012/02/19 07:52:30 otto Exp $ */
@ -34,7 +34,7 @@
#include <locale.h>
#endif
__RCSID("$MirOS: src/bin/mksh/main.c,v 1.269 2013/07/25 18:07:46 tg Exp $");
__RCSID("$MirOS: src/bin/mksh/main.c,v 1.270 2013/09/10 17:33:02 tg Exp $");
extern char **environ;
@ -76,7 +76,6 @@ static const char *initcoms[] = {
/* not in Android for political reasons */
/* not in ARGE mksh due to no job control */
"stop=kill -STOP",
"suspend=kill -STOP $$",
#endif
"autoload=typeset -fu",
"functions=typeset -f",