[mod.computers.pyramid] rogomatic on pyramids

romain@pyrnj.UUCP (11/03/85)

<frivolous on>
I need a vacation, but don't have time for it right now.  So to
compensate, I started running infinite loops of Rog-O-Matic (from
Carnegie-Mellon University) on my officemate's terminal.  However, it
took so long to start up I noticed it even when I was working at other
things on my own terminal.  I got curious and gcore'd the player
process to find it trying to lock
	"\027F$=/games/lib/rgm/rlog/GeneLock521".

A little more detective work showed that the lockfile name was getting
created correctly, but getting trashed.  The fix:
Change this line in rand.c
	if (seed == 0) seed = time();
to
	if (seed == 0) seed = time(0);
since 4.2 time() stuffs the time into *(parameter register 0) if it's
non-null.  In this case, pr0 always pointed at genelock[] because of
the Pyramid register window mechanism.

There remain other things in Rog-O-Matic that need to be patched up.
It looks as if some strings or pointers passed through match() are
sometimes getting corrupted.  I've been seeing a lot of loops where rgm
doesn't recognize strings of the form "you can't*".  (How's that for
optimistic programming?)

Moral of the story: Even good programmers can write non-portable code
on a bad day.  All those little warnings from lint may eventually catch
up with you...

Romain Kang, Pyramid Technology Corporation

US Mail:	900 Route 9, Woodbridge, NJ  07095
Ma Bell:	(201) 750-2626
UUCPnet:	{allegra,cmcl2,pyramid,topaz}!pyrnj!romain

"!!!x09 dimaryP a fo edisni deppart m'I !pleH"

"oNhwre eenraa  sab dsab iegnt arppdei  n aAV X117/05!!!"