OSDN Git Service

do not write comment if the file handle has been closed
authortkaneko <tkaneko@b8c68f68-1e22-0410-b08e-880e1f8202b4>
Mon, 6 Mar 2006 15:38:30 +0000 (15:38 +0000)
committertkaneko <tkaneko@b8c68f68-1e22-0410-b08e-880e1f8202b4>
Mon, 6 Mar 2006 15:38:30 +0000 (15:38 +0000)
shogi-server

index 5f78607..22ba46b 100755 (executable)
@@ -241,7 +241,7 @@ class Player
               comment = array_str.unshift("'*#{$1}")
             end
             s = @game.handle_one_move(move, self)
-            @game.fh.print("#{comment}\n") if comment
+            @game.fh.print("#{comment}\n") if (comment && !s)
             return if (s && @protocol == "CSA")
           end
         when /^%[^%]/, :timeout