Path: utzoo!utgpu!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!rutgers!cmcl2!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn ) Newsgroups: comp.unix.wizards Subject: Re: script & lock Message-ID: <9260@smoke.BRL.MIL> Date: 2 Jan 89 04:37:57 GMT References: <17972@adm.BRL.MIL> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 9 In article <17972@adm.BRL.MIL> drears@ardec.arpa (Dennis G. Rears (FSAC)) writes: > This happens on a VAX 8600 running ULTRIK but does not happen on >Goulds or Pyramids. I have a lock program I wrote several years >ago. When I run it on top of /usr/ucb/script I get a Bus Error when I >type in my password. Any idea why? ... getlogin() can, and probably does when run under "script", return NULL. You didn't test for this and so you tried to strcmp() with the second argument NULL. strcmp() trusted you and you let it down..