[mythtv-commits] Ticket #9918: Incorrect character encoding in xml status (patch provided)

MythTV noreply at mythtv.org
Tue Jul 12 11:45:43 UTC 2011


#9918: Incorrect character encoding in xml status (patch provided)
-------------------------------------+-------------------------------------
 Reporter:  Ian Dall <ian@…>         |           Type:  Bug Report -
   Status:  new                      |  General
Milestone:  unknown                  |       Priority:  minor
  Version:  Unspecified              |      Component:  MythTV - General
 Keywords:  xml encoding             |       Severity:  medium
                                     |  Ticket locked:  0
-------------------------------------+-------------------------------------
 Fetching the xml status, eg by

 wget http://mythmaster:6544/Status/xml

 Yields incorrect xml when non-ascii characters are in the relevant program
 descriptions. Here in Australia, channel 10 likes to assert copyright over
 the program information and puts the copyright symbol into its EIT data.

 In  HttpStatus::GetStatusXML() the output uses QDomDocument::stream()
 which defaults to the locale character encoding, whereas the default
 encoding for xml is UTF-8.

 We need to user stream.setCodec("UTF-8") to set the encoding. Preferably
 we also want a
 {{{
 <?xml version="1.0" encoding="UTF-8"?>
 }}}
 string to specify the xml decoding. In principle another encoding could be
 chosen, but there seems no reason not to use UTF-8.

-- 
Ticket URL: <http://code.mythtv.org/trac/ticket/9918>
MythTV <http://code.mythtv.org/trac>
MythTV Media Center


More information about the mythtv-commits mailing list