diff arogue7/passages.c @ 200:1cd604c827a3

Advanced Rogue 7: initialize multiple variables. MSVC complained that they might be used uninitialized. In some cases, this might have been possible. XRogue already has initializations for all these variables.
author John "Elwin" Edwards
date Wed, 12 Aug 2015 15:42:02 -0400
parents adfa37e67084
children f9ef86cf22b2
line wrap: on
line diff
--- a/arogue7/passages.c	Tue Aug 11 16:19:04 2015 -0400
+++ b/arogue7/passages.c	Wed Aug 12 15:42:02 2015 -0400
@@ -28,7 +28,7 @@
 
 do_passages()
 {
-    register struct rdes *r1, *r2;
+    register struct rdes *r1, *r2 = NULL;
     register int i, j;
     register int roomcount;
     static struct rdes
@@ -137,7 +137,7 @@
 conn(r1, r2)
 int r1, r2;
 {
-    register struct room *rpf, *rpt;
+    register struct room *rpf, *rpt = NULL;
     register char rmt;
     register int distance, max_diag, offset, i;
     register int rm;