From: H.G. Muller Date: Sun, 15 Jan 2012 20:24:12 +0000 (+0100) Subject: Fix printing non-numeric kibitz with -autoKibitz X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=fa54fde4cfec7ae5d4501879ac42f621c33db4dd;hp=278e742af91281ce50be123980253bc35b1143a1;p=xboard.git Fix printing non-numeric kibitz with -autoKibitz Messages that were not considered kibitzed engine PV info for lack of numeric content, were kibitzed as coming from "your opponent", which is nonsense if you were iobserving, and masked the source. Fortunately star_match[0] is still holding the original name, at that point. --- diff --git a/backend.c b/backend.c index f2aae99..6d0708d 100644 --- a/backend.c +++ b/backend.c @@ -2929,6 +2929,9 @@ read_from_ics (InputSourceRef isr, VOIDSTAR closure, char *data, int count, int OutputKibitz(suppressKibitz, parse); } else { char tmp[MSG_SIZ]; + if(gameMode == IcsObserving) // restore original ICS messages + snprintf(tmp, MSG_SIZ, "%s kibitzes: %s", star_match[0], parse); + else snprintf(tmp, MSG_SIZ, _("your opponent kibitzes: %s"), parse); SendToPlayer(tmp, strlen(tmp)); }