Opened 11 years ago
Closed 10 years ago
#11812 closed Bug Report - General (fixed)
Mythutil --pidprinter --xml output is NOT valid XML
Reported by: | Owned by: | Karl Egly | |
---|---|---|---|
Priority: | minor | Milestone: | 0.28 |
Component: | MythTV - DVB | Version: | Master Head |
Severity: | medium | Keywords: | |
Cc: | Ticket locked: | no |
Description
The output from mythutil --pidprinter --xml is not well formed for several reasons: 1) it does not have the leading <?xml> processing instruction. 2) It does not have a proper master node - if you dump several types of PSIP entry it will create each one at the top level, rather than as sub-nodes of the parent. 3) Nodes are not being properly XML escaped, so 3a) attributes are being created containing un-escaped quotes (example: <ProgramMapSection? pcr_pid="0x31" program_number="1"
program_info_length="17" stream_count="table_id="0x02" length="124" section="0" last_section="0""%8>
) 3b) Attributes can contain characters that need to be escaped in XML, such as < and & (example: <Decoded>Audio Stream Descriptor full_srv(1) sample_rate(48kbps) bit_rate(<=384kbps, 46)
bsid(8) bs_mode(0) channels(<= 6) Dolby(Not indicated) mainID(0) </Decoded>
Note the unescaped "<=384" in the XML. ) 4) Junk at the end of the ProgramMapSection? tag: (example: see above - note the %8> at the end of the tag.).
Change History (7)
comment:1 Changed 11 years ago by
Component: | MythTV - General → MythTV - DVB |
---|---|
Milestone: | 0.27 → 0.28 |
Owner: | set to danielk |
comment:2 Changed 11 years ago by
Owner: | changed from danielk to Karl Egly |
---|---|
Status: | new → assigned |
comment:3 Changed 11 years ago by
comment:5 Changed 11 years ago by
Note to self: need to look into an issue with PrintOutput::Output when m_out is NULL. The LOG output does not make it to stdout which is confusing when testing. Using --outfile /dev/stdout works though. https://github.com/MythTV/mythtv/blob/master/mythtv/programs/mythutil/mpegutils.cpp#L422
comment:7 Changed 10 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
In 37d9be84c43ac35fd533f1beab4cc7dec8ae6884/mythtv: