]> granicus.if.org Git - nethack/commitdiff
unix+vms wizard mode feedback (trunk only)
authornethack.rankin <nethack.rankin>
Tue, 19 Jan 2010 02:58:59 +0000 (02:58 +0000)
committernethack.rankin <nethack.rankin>
Tue, 19 Jan 2010 02:58:59 +0000 (02:58 +0000)
     The message "only user <foo> may use wizard mode" formerly given
by the Unix and VMS ports was inadvertently rendered impossible to be
delivered when authorize_wizard_mode() was added to xxxmain.c nearly
3 years ago.

sys/unix/unixmain.c
sys/vms/vmsmain.c

index 7e3342a4497d4da56a26500298b80b05642fef8e..9a6cbb418847f93933bd9c0d1be55d27bd6cdf39 100644 (file)
@@ -575,6 +575,7 @@ authorize_wizard_mode()
 #endif
        if (pw && !strcmp(pw->pw_name, WIZARD_NAME)) return TRUE;
 #endif /* WIZARD */
+       wiz_error_flag = TRUE;  /* not being allowed into wizard mode */
        return FALSE;
 }
 
index 6cc7b2b3bf8e41a493a369a678790a95b22df366..1b15175a1f987b600df76890b0f4f8e7645c5a25 100644 (file)
@@ -1,5 +1,4 @@
 /* NetHack 3.5 vmsmain.c       $Date$  $Revision$ */
-/*     SCCS Id: @(#)vmsmain.c  3.5     2008/01/30      */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /* NetHack may be freely redistributed.  See license for details. */
 /* main.c - VMS NetHack */
@@ -454,6 +453,7 @@ authorize_wizard_mode()
 #ifdef WIZARD
        if (!strcmpi(nh_getenv("USER"), WIZARD_NAME)) return TRUE;
 #endif
+       wiz_error_flag = TRUE;  /* not being allowed into wizard mode */
        return FALSE;
 }