[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnugo-devel] gtp dragon_status bug
From: |
Evan Daniel |
Subject: |
[gnugo-devel] gtp dragon_status bug |
Date: |
Fri, 10 Jun 2005 20:22:31 -0400 |
If the gtp function dragon_status is called on the empty board, GNU Go
only prints one newline, not the required two. Patch below.
Evan Daniel
Index: interface/play_gtp.c
===================================================================
RCS file: /cvsroot/gnugo/gnugo/interface/play_gtp.c,v
retrieving revision 1.167
diff -u -d -r1.167 play_gtp.c
--- interface/play_gtp.c 17 Apr 2005 19:36:42 -0000 1.167
+++ interface/play_gtp.c 11 Jun 2005 00:20:59 -0000
@@ -2224,6 +2224,7 @@
int i, j;
int str = NO_MOVE;
int pos;
+ int empty_response = 1;
if (gtp_decode_coord(s, &i, &j)) {
str = POS(i, j);
@@ -2262,9 +2263,13 @@
I(DRAGON2(pos).owl_defense_point),
J(DRAGON2(pos).owl_defense_point));
}
+ empty_response = 0;
}
}
+ if (empty_response)
+ gtp_printf("\n");
+
gtp_printf("\n");
return GTP_OK;
}
- [gnugo-devel] gtp dragon_status bug,
Evan Daniel <=