aboutsummaryrefslogtreecommitdiffstats
path: root/sbin/sysinstall/exec.c
diff options
context:
space:
mode:
authorPoul-Henning Kamp <phk@FreeBSD.org>1994-10-29 10:01:40 +0000
committerPoul-Henning Kamp <phk@FreeBSD.org>1994-10-29 10:01:40 +0000
commitaa7d974a35f2ae76a93e9454129d1945462cf221 (patch)
tree14ec12c1ae896a3b10086e7451c63766efda7db0 /sbin/sysinstall/exec.c
parente2247bbffdecc8dea6c55cea6df5aff29bed4a83 (diff)
downloadsrc-aa7d974a35f2ae76a93e9454129d1945462cf221.tar.gz
src-aa7d974a35f2ae76a93e9454129d1945462cf221.zip
Fixed to make sysinstall work again. Notable changes:
Removed a dialog_clear() which somebody aimlessly had slammed into TellEm() in absence of any understanding of the structure of this program. :-( Skip through stage0 for now. Make write_bootblocks write the disklabel using the kernel-call, and forget about the boot-blocks for now. This is wrong, but I havn't found the real problem yet. I will continue work on this problem. Added a Debug-feature. There is a printf' like Debug() now which sends its output to ttyv1 (Alt-F2), and all "discarded output" from sub-processes end up there too. Made TellEm() put it's messages there also, so that we can see where what happens. Set the PATH for the shell we shouldn't start at the end :-) set "npartitions" after the disklabel-editor returns, so that we actually can edit all the 8 parts of the label.
Notes
Notes: svn path=/head/; revision=3987
Diffstat (limited to 'sbin/sysinstall/exec.c')
-rw-r--r--sbin/sysinstall/exec.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/sbin/sysinstall/exec.c b/sbin/sysinstall/exec.c
index cbe9b744af31..d1ec7f515306 100644
--- a/sbin/sysinstall/exec.c
+++ b/sbin/sysinstall/exec.c
@@ -6,7 +6,7 @@
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
* ----------------------------------------------------------------------------
*
- * $Id: exec.c,v 1.2 1994/10/21 05:36:42 phk Exp $
+ * $Id: exec.c,v 1.4 1994/10/26 05:40:59 phk Exp $
*
*/
@@ -52,14 +52,17 @@ exec(int magic, char *cmd, char *args, ...)
if ((pid = fork()) == 0) {
switch (magic) {
case 0:
- close(0); open("/dev/null",O_RDONLY);
- close(1); open("/dev/null",O_WRONLY);
- close(2); open("/dev/null",O_WRONLY);
+ close(0); dup(debug_fd);
+ close(1); dup(debug_fd);
+ close(2); dup(debug_fd);
+ close(debug_fd);
break;
case 1:
- close(2); open("/dev/null",O_WRONLY);
+ close(2); dup(debug_fd);
+ close(debug_fd);
break;
case 2:
+ close(debug_fd);
default:
break;
}