🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: net.games.hack
Article #535

Re: Bug in hack 1.0.1

#535
From: Brian Siritzky
Date: Thu, 02 May 1985 16:58
47 lines
2095 bytes
/* acf2:net.games.hack / don@axiom.UUCP (Donald F. Picard) /  7:14 pm  Apr 30, 1985 */
[]

There is a bug in version 1.0.1 ( I don't know if it is in 1.0.2 because
I haven't brought it up yet) in the file "hack.stat.c".  The game
checks the inode change time of files against the inode change time of
the game to make sure that they (the files) are up to date.  I assume
that this is an attempt to make sure that people are not trying to
restore saved games (and ghost levels) that were created under a previous
version of the game.  The only problem is that the inode change time
gets updated for a lot of reasons, not just "file creation".

I recently lost a saved game (and a good one too!) because somebody here
made a symbolic link to the game. (Don't ask me why.)  This updated the
inode change time of the game and so the next time I tried to play
it told me that my saved game was out of date and threw it away!

I don't know why the author chose to check the c_time field over the
m_time field, but that is my suggested fix.

A context diff follows.

					Don Picard
					Axiom Technology
					... linus!axiom!don

*** hack.stat.c
--- hack.stat.c.new
***************
*** 17,23
  		pline("Cannot get status?");
  		return(0);
  	}
! 	if(buf.st_ctime < hbuf.st_ctime) {
  		pline("Saved level is out of date.");
  		return(0);
  	}

--- 17,23 -----
  		pline("Cannot get status?");
  		return(0);
  	}
! 	if(buf.st_mtime < hbuf.st_mtime) {
  		pline("Saved level is out of date.");
  		return(0);
  	}
/* ---------- */
Technical Details
Message-ID: <2360003@acf2.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!linus!philabs!cmcl2!acf2!siritzky
References: <38@axiom.UUCP>

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version nyu B notes v1.5 12/10/84; site acf2.UUCP
Path: arc1-ca.pugleaf.net!utzoo!linus!philabs!cmcl2!acf2!siritzky
From: siritzky@acf2.UUCP (Brian Siritzky)
Newsgroups: net.games.hack
Subject: Re: Bug in hack 1.0.1
Message-ID: <2360003@acf2.UUCP>
Date: Thu, 2-May-85 12:58:00 EDT
Article-I.D.: acf2.2360003
Posted: Thu May  2 12:58:00 1985
Date-Received: Sat, 4-May-85 09:08:48 EDT
References: <38@axiom.UUCP>
Organization: New York University
Lines: 47