File: leval.c.patch

package info (click to toggle)
sjeng 11.2-15
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 1,436 kB
  • sloc: ansic: 13,378; sh: 324; makefile: 29
file content (21 lines) | stat: -rw-r--r-- 672 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
Author: Lukas Geyer <geyer@math.uni-dortmund.de>
Description: General code cleanup, added initializers.

--- sjeng-11.2.orig/leval.c
+++ sjeng-11.2/leval.c
@@ -120,13 +120,13 @@
 long int losers_eval (void) {
 
   /* return a score for the current middlegame position: */
-  int srank, pawn_file, pawns[2][11], white_back_pawn[11], black_back_pawn[11];
+  int srank = 0, pawn_file = 0, pawns[2][11], white_back_pawn[11], black_back_pawn[11];
   int isolated, backwards;
   int i, a, j;
   long int score = 0;
   int in_cache;
   int wp = 0, bp = 0;
-  int wks, bks;
+  int wks = 0, bks = 0;
   int wpassp = 0, bpassp = 0;
   int wpawns = 0, bpawns = 0;