I run pidgin-2.13.0-1.fc28.1.x86_64 (with purple-sipe-1.23.2-1.fc28.x86_64) on Linux. My teammate run MS Lync on Windows. Messages typed in Lync are delivered perfectly. However, if my teammate copy-n-paste multiline text from another application, it is delivered to me as single line.
I tried to track down the bug. The first control point is in src/core/sipe-incoming.c file, function process_incoming_message:
SIPE_DEBUG_INFO("got message from %s: %s", from, msg->body);
At this point msg->body looks like:
<P style='margin-bottom:0pt; font-size:10pt; font-family:"Segoe UI",sans-serif; color:black; line-height:normal;'>1</P><P style='margin-bottom:0pt; font-size:10pt; font-family:"Segoe UI",sans-serif; color:black; line-height:normal;'>2</P>
HTML code looks ok. We received two paragraphs, the first line is "1" and the second line is "2".
It is not chat, so the message is passed to
sipe_backend_im_message(SIPE_CORE_PUBLIC,
from,
html);
sipe_backend_im_message is defined in src/purple/purple-im.c and is trivial:
void sipe_backend_im_message(struct sipe_core_public *sipe_public,
const gchar *from,
const gchar *html)
{
struct sipe_backend_private *purple_private = sipe_public->backend_private;
purple_serv_got_im(purple_private->gc,
from,
html,
0,
time(NULL));
}
html is just passed to the purple_serv_got_im, and finally, the message appears in Pidgin as one line:
12
while I would expect it is displayed as two lines:
1
2
Frankly, I am not sure if it is a purple-sipe or purple bug. I am not an experienced in purple development. If you say it is a purple bug, I'll resubmit it to purple tracker.
Thanks.
This has been discussed multiple times already, e.g. [bugs:#289]
Closing as DUPLICATE
Related
Bugs:
#289