|
|
@ -801,11 +801,17 @@ ttynew(void) {
|
|
|
|
close(s);
|
|
|
|
close(s);
|
|
|
|
cmdfd = m;
|
|
|
|
cmdfd = m;
|
|
|
|
signal(SIGCHLD, sigchld);
|
|
|
|
signal(SIGCHLD, sigchld);
|
|
|
|
if(opt_io && !(fileio = fopen(opt_io, "w"))) {
|
|
|
|
if(opt_io) {
|
|
|
|
|
|
|
|
if(!strcmp(opt_io, "-")) {
|
|
|
|
|
|
|
|
fileio = stdout;
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
if(!(fileio = fopen(opt_io, "w"))) {
|
|
|
|
fprintf(stderr, "Error opening %s:%s\n",
|
|
|
|
fprintf(stderr, "Error opening %s:%s\n",
|
|
|
|
opt_io, strerror(errno));
|
|
|
|
opt_io, strerror(errno));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
void
|
|
|
|