From 537718980dadf54d83cdfc3f2b1fa54444d064ba Mon Sep 17 00:00:00 2001 From: "nethack.rankin" Date: Tue, 21 Oct 2003 04:25:35 +0000 Subject: [PATCH] vms catchup 1) filename manipulation during restore 2) hangup handling in low level input routine 3) Makefile dependencies 4) version number update --- sys/vms/Install.vms | 10 +++++----- sys/vms/Makefile.src | 4 ++-- sys/vms/vmsbuild.com | 2 +- sys/vms/vmsmain.c | 4 ++-- sys/vms/vmstty.c | 14 ++++++++++---- 5 files changed, 20 insertions(+), 14 deletions(-) diff --git a/sys/vms/Install.vms b/sys/vms/Install.vms index 994b855e5..289bd4275 100644 --- a/sys/vms/Install.vms +++ b/sys/vms/Install.vms @@ -1,4 +1,4 @@ - Instructions for Installing NetHack 3.4.2 + Instructions for Installing NetHack 3.4.3 on a VMS (aka OpenVMS) system ========================================= @@ -7,7 +7,7 @@ 1. Building NetHack requires a C compiler (either Compaq C, DEC C, VAX C, or GNU C) and VMS version V4.6 or later (but see note #9). - This release has been tested with Compaq C V6.4 on Alpha/VMS V7.1 + This release has been tested with Compaq C V6.4 on Alpha/VMS V7.3-1 and with VAX C V3.2 and GNU C 2.7.1 on VAX/VMS V5.5-2. The build procedure (vmsbuild.com) should not need to be modified; it accepts an option for selecting the compiler, and it can detect different @@ -136,8 +136,8 @@ Notes: -1. Save files and bones files from versions 3.4.0 and 3.4.1 will work - with 3.4.2; those from earlier versions will not. The scoreboard +1. Save files and bones files from versions 3.4.0, 3.4.1 and 3.4.2 will + work with 3.4.3; those from earlier versions will not. The scoreboard file (RECORD) from 3.4.x or 3.3.x will also work; one from version 3.2.x is slightly different format but should be compatible. @@ -476,4 +476,4 @@ Notes: Always include version information for NetHack, the operating system, and the C compiler used. -21-AUG-2003 +20-OCT-2003 diff --git a/sys/vms/Makefile.src b/sys/vms/Makefile.src index 3a105e31a..1d6a36de3 100644 --- a/sys/vms/Makefile.src +++ b/sys/vms/Makefile.src @@ -90,7 +90,7 @@ RANDOBJ = random.obj # Other things that have to be reconfigured are in vmsconf.h, # and config.h -VERSION = 3.4.2 +VERSION = 3.4.3 MAKEDEFS = $(UTL)makedefs.exe; @@ -368,7 +368,7 @@ do_wear.obj : do_wear.c $(HACK_H) dog.obj : dog.c $(HACK_H) $(INC)edog.h dogmove.obj : dogmove.c $(HACK_H) $(INC)mfndpos.h $(INC)edog.h dokick.obj : dokick.c $(HACK_H) $(INC)eshk.h -dothrow.obj : dothrow.c $(HACK_H) +dothrow.obj : dothrow.c $(HACK_H) $(INC)edog.h drawing.obj : drawing.c $(HACK_H) $(INC)tcap.h dungeon.obj : dungeon.c $(HACK_H) $(INC)dgn_file.h $(INC)dlb.h eat.obj : eat.c $(HACK_H) diff --git a/sys/vms/vmsbuild.com b/sys/vms/vmsbuild.com index 603947113..7a0b3bac4 100755 --- a/sys/vms/vmsbuild.com +++ b/sys/vms/vmsbuild.com @@ -1,5 +1,5 @@ $ ! vms/vmsbuild.com -- compile and link NetHack 3.4.* [pr] -$ version_number = "3.4.2" +$ version_number = "3.4.3" $ ! $ ! usage: $ ! $ set default [.src] !or [-.-.src] if starting from [.sys.vms] diff --git a/sys/vms/vmsmain.c b/sys/vms/vmsmain.c index fe09744d9..c2ad1e6da 100644 --- a/sys/vms/vmsmain.c +++ b/sys/vms/vmsmain.c @@ -1,4 +1,4 @@ -/* SCCS Id: @(#)vmsmain.c 3.4 2003/09/25 */ +/* SCCS Id: @(#)vmsmain.c 3.4 2003/10/16 */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* NetHack may be freely redistributed. See license for details. */ /* main.c - VMS NetHack */ @@ -183,7 +183,7 @@ char *argv[]; */ boolean remember_wiz_mode = wizard; #endif - const char *fq_save = fqname(SAVEF, SAVEPREFIX, 0); + const char *fq_save = fqname(SAVEF, SAVEPREFIX, 1); (void) chmod(fq_save,0); /* disallow parallel restores */ (void) signal(SIGINT, (SIG_RET_TYPE) done1); diff --git a/sys/vms/vmstty.c b/sys/vms/vmstty.c index 894c1eff8..314a91230 100644 --- a/sys/vms/vmstty.c +++ b/sys/vms/vmstty.c @@ -1,4 +1,4 @@ -/* SCCS Id: @(#)vmstty.c 3.4 2002/08/21 */ +/* SCCS Id: @(#)vmstty.c 3.4 2003/09/18 */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* NetHack may be freely redistributed. See license for details. */ /* tty.c - (VMS) version */ @@ -106,12 +106,20 @@ int vms_getchar() { short key; - #ifdef USE_QIO_INPUT struct _rd_iosb iosb; unsigned long sts; unsigned char kb_buf; +#else /* SMG input */ + static volatile int recurse = 0; /* SMG is not AST re-entrant! */ +#endif + + if (program_state.done_hup) { + /* hangup has occurred; do not attempt to get further user input */ + return ESC; + } +#ifdef USE_QIO_INPUT if (inc > 0) { /* we have buffered character(s) from previous read */ kb_buf = *inp++; @@ -146,8 +154,6 @@ vms_getchar() key = getchar(); #else /*!USE_QIO_INPUT*/ - static volatile int recurse = 0; /* SMG is not AST re-entrant! */ - if (recurse++ == 0 && kb != 0) { smg$read_keystroke(&kb, &key); switch (key) { -- 2.40.0