Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10 5/3/83; site west44.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxl!houxm!houxz!vax135!ukc!west44!lee From: lee@west44.UUCP (Lee McLoughlin) Newsgroups: net.unix-wizards Subject: SH buglette. Message-ID: <262@west44.UUCP> Date: Mon, 2-Jul-84 20:16:52 EDT Article-I.D.: west44.262 Posted: Mon Jul 2 20:16:52 1984 Date-Received: Tue, 3-Jul-84 03:19:26 EDT Organization: CS Dept., Westfield College, London Lines: 27 I was poking around in our shell (V7) source and found the following in main.c. userid=getuid(); /* decide whether interactive */ /* * NJH 20.5.82 * now use ioctl not gtty */ IF (flags&intflg) ORF ((flags&oneflg)==0 ANDF ioctl(output,TIOCGETP,&statb)==0 ANDF ioctl(input,TIOCGETP,&statb)==0) THEN dfault(&ps1nod, (userid?stdprompt:supprompt)); dfault(&ps2nod, readmsg); flags |= ttyflg|prompt; ignsig(KILL); Then did a double take. The ioctl's do work instead of the gtty/stty but what is this strange looking statb? In our source it is declared as a struct statb! The fix is obvious, declare and use a struct sgtty instead. I've found the same buglette at another V7 site. This is probably an old bug but I thought I'd mention it anyway. -- -------------- Lee McLoughlin !ukc!lmcl, west44!lee UKUUCP support.