Download & Extend

problems with some versions of libxml2 and php cause xml-rpc content to have tags mangled

Project:Drupal core
Version:6.10
Component:other
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active

Issue Summary

This problem was noticed while using:
libxml2 v 2.7.2

works fine using:
libxml2 v 2.6.31

This error is described Here it is supposedly fixed in the latest version of PHP but not all Drupal users can control the version of PHP or libxml2 they are using. I have noticed that the main culprit is libxml2

I propose a fix based on this proposed fix for Wordpress:

Replace the characters that are removed from the xml-rpc message before the parser has a chance to remove then unnecessarily.

<?php
  $xmlrpc_message
->message = str_replace('&lt;','&#60;', $xmlrpc_message->message );
 
$xmlrpc_message->message = str_replace('&gt;','&#62;', $xmlrpc_message->message );
 
$xmlrpc_message->message = str_replace('&amp;','&#38;', $xmlrpc_message->message );
?>
AttachmentSizeStatusTest resultOperations
drupal_core_6.x_xmlrpc_html_tags_mangled.patch943 bytesIgnored: Check issue status.NoneNone
drupal_core_HEAD_xmlrpc_html_tags_mangled.patch931 bytesIgnored: Check issue status.NoneNone
nobody click here