summaryrefslogtreecommitdiff
path: root/games/xdemineur/patches/patch-aa
diff options
context:
space:
mode:
Diffstat (limited to 'games/xdemineur/patches/patch-aa')
-rw-r--r--games/xdemineur/patches/patch-aa34
1 files changed, 34 insertions, 0 deletions
diff --git a/games/xdemineur/patches/patch-aa b/games/xdemineur/patches/patch-aa
new file mode 100644
index 00000000000..8928bd7ff82
--- /dev/null
+++ b/games/xdemineur/patches/patch-aa
@@ -0,0 +1,34 @@
+$NetBSD: patch-aa,v 1.1 1999/12/29 16:18:53 bad Exp $
+
+--- demineur.c.orig Thu Jul 29 23:25:30 1999
++++ demineur.c Sun Nov 14 23:28:02 1999
+@@ -71,20 +71,18 @@
+
+ if ( option_mines != 0 )
+ {
+- if ( option_mines >= board.rows * board.columns )
+- {
+- printf ( "Too many mines, using default number.\n" ) ;
+- mines = board.mines = board.rows * board.columns / 4.8 ;
+- }
+- else
+- {
+- mines = board.mines = option_mines ;
+- }
++ board.mines = option_mines; /* override default */
+ }
+- else
++ if ( board.mines >= board.rows * board.columns )
+ {
+- mines = board.mines = board.rows * board.columns / 4.8 ;
++ printf ( "Too many mines, using default number.\n" ) ;
++ board.mines = 0;
+ }
++ if ( board.mines == 0 ) /* if not set yet, use default */
++ {
++ board.mines = board.rows * board.columns / 4.8 ;
++ }
++ mines = board.mines;
+
+ elapsed = 0 ;
+ state = PLAYING ;