Date: Tue, 2 Mar 1999 11:08:10 -0800 (PST) From: Joerg Wunsch <joerg@FreeBSD.org> To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/usr.bin/window wwinit.c wwspawn.c Message-ID: <199903021908.LAA40787@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
joerg 1999/03/02 11:08:10 PST
Modified files:
usr.bin/window wwinit.c wwspawn.c
Log:
Make window(1) actually work again. It has been broken for quite some
time now.
For whatever reason, the kernel seems to have generated SIGIOs
previously without an initial fcntl(...,F_SETOWN), but does no longer.
This caused window(1) to wait indefinitely for input.
Also, undo rev 1.3 of wwspawn.c, it was not well-thought, and
apparently not even tested at all. The blindly (even in a nonsensical
place like the comment on top of the function) applied replacement of
vfork() by fork() totally ignored that window(1) *does* abuse the
feature of vfork() where a modification of the parent's address space
is possible (in this case, to notify the parent of an erred exec*).
Also, with vfork(), it is guaranteed that the parent is only woken up
after the exec*() happened, where the replacement by fork() made the
parent to almost always become runnable again before the child, in
which case the parent simply told `subprocess died'. Unfortunately,
working around _this_ seems to be a lot more of redesign work compared
to little gained value, so i think relying on the specifics of vfork()
is the simpler way.
Submitted by: Philipp Mergenthaler <un1i@rz.uni-karlsruhe.de>
Revision Changes Path
1.10 +1 -0 src/usr.bin/window/wwinit.c
1.4 +2 -2 src/usr.bin/window/wwspawn.c
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199903021908.LAA40787>
