Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!seismo!sundc!texsun!sun!imagen!kchen From: kchen@imagen.UUCP (Kok Chen) Newsgroups: comp.os.minix Subject: Minor bug in tty.c Message-ID: <1383@imagen.UUCP> Date: Sun, 16-Aug-87 18:07:11 EDT Article-I.D.: imagen.1383 Posted: Sun Aug 16 18:07:11 1987 Date-Received: Mon, 17-Aug-87 04:46:49 EDT Organization: Imagen Corp., Santa Clara CA Lines: 22 The function out_char() in tty.c has a minor bug (apparently not corrected in ast's 1.2 release diff). Corresponding to line 4294 of the listing (page 519) in the "bible," the line should read: tp->tty_ramqueue[tp->tty_rwords++] = tp->tty_attribute | ( c & 0xff ) ; ------------ The masking with 0xff was missing in the original code. Since c was declared as a char, any usage of the extended character set of the PC (e.g. the crude "graphics" symbols) causes the video attribute bits to be turned on through sign extension (bad for epileptics :-). Many thanks to ast for MINIX. Never had so much fun hacking since the RPC-4000 and the early TOPS-20 days!!! Kok S. Chen ..!decwrl!imagen!kchen Imagen Corporation -------- P.S. the hard disk seems perfectly stable (modulo the programmed-hard- error-blocks problem) with ast's recent 1.2 at_wini.c posting. System is a 10 MHz (0 wait) AT clone with a WD controller.