X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=winboard%2Fwchat.c;h=b02e00e1c6c8562af871099a14889a29a43c561b;hb=9f8e3f62352236d94f044b198a897488d404ed7e;hp=eb5179ff4ba6f1e762db18070884215420b77bb7;hpb=ba19c79e683860fba8cafa5ca24b0f8191b4c1d5;p=xboard.git diff --git a/winboard/wchat.c b/winboard/wchat.c index eb5179f..b02e00e 100644 --- a/winboard/wchat.c +++ b/winboard/wchat.c @@ -208,7 +208,7 @@ LRESULT CALLBACK ChatProc( HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam sprintf(buf, "whisper %s\n", mess); // WHISPER box uses "whisper" to send else { if(!atoi(chatPartner[partner])) { - sprintf(buf, "> %s\n", mess); // echo only tells to handle, not channel + sprintf(buf, "> %s\r\n", mess); // echo only tells to handle, not channel InsertIntoMemo(hDlg, buf); sprintf(buf, "xtell %s %s\n", chatPartner[partner], mess); } else @@ -287,5 +287,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); }