From: H.G. Muller Date: Wed, 10 Feb 2010 09:58:29 +0000 (+0100) Subject: Fix copying of WB Chat Window contents X-Git-Tag: v4.4.3.20100220~5 X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=add17fd2668118b7c00fa0cb7065b8c34836d886;hp=f3613d892c55647b27b0d42b9766e7435e32794b;p=xboard.git Fix copying of WB Chat Window contents All line breks were lost on copy-pasting the contents of a chat window. Adding CR to each outputted line in the front-end (wchat.c) solves this. --- diff --git a/winboard/wchat.c b/winboard/wchat.c index 93e5ee1..4cf8dce 100644 --- a/winboard/wchat.c +++ b/winboard/wchat.c @@ -279,5 +279,7 @@ void OutputChatMessage(int partner, char *text) { if(!chatHandle[partner]) return; + int n = strlen(text); + text[n+1] = 0; text[n] = '\n'; text[n-1] = '\r'; // Needs CR to not lose line breaks on copy-paste InsertIntoMemo(chatHandle[partner], text); }