Skip to content

Conversation

@cfsmp3
Copy link
Contributor

@cfsmp3 cfsmp3 commented Dec 8, 2025

Summary

  • Fixed write_spucomment to handle double-hyphens (--) which are invalid inside XML comments
  • The fix removes one hyphen when encountering -- sequences to produce valid XML output
  • Rebased onto current master
  • Applied clang-format

Supersedes #1642

Test plan

  • Generate SPUPNG output with captions containing --
  • Verify the resulting XML is valid

🤖 Generated with Claude Code

@cfsmp3 cfsmp3 changed the title [FIX] Use memset instead of incorrect sprintf assignment in spupng [FIX] Handle double-hyphens in XML comments in spupng encoder Dec 8, 2025
@ccextractor-bot
Copy link
Collaborator

CCExtractor CI platform finished running the test files on linux. Below is a summary of the test results, when compared to test for commit 60ae6fb...:
Report Name Tests Passed
Broken 13/13
CEA-708 14/14
DVB 7/7
DVD 3/3
DVR-MS 2/2
General 27/27
Hardsubx 0/1
Hauppage 3/3
MP4 3/3
NoCC 10/10
Options 86/86
Teletext 21/21
WTV 13/13
XDS 34/34

Your PR breaks these cases:


It seems that not all tests were passed completely. This is an indication that the output of some files is not as expected (but might be according to you).

Check the result page for more info.

@ccextractor-bot
Copy link
Collaborator

CCExtractor CI platform finished running the test files on windows. Below is a summary of the test results, when compared to test for commit da03c1e...:
Report Name Tests Passed
Broken 13/13
CEA-708 14/14
DVB 4/7
DVD 3/3
DVR-MS 2/2
General 27/27
Hardsubx 0/1
Hauppage 3/3
MP4 3/3
NoCC 10/10
Options 86/86
Teletext 7/21
WTV 13/13
XDS 34/34

Your PR breaks these cases:

NOTE: The following tests have been failing on the master branch as well as the PR:


It seems that not all tests were passed completely. This is an indication that the output of some files is not as expected (but might be according to you).

Check the result page for more info.

@cfsmp3 cfsmp3 merged commit 810e02f into master Dec 8, 2025
28 of 30 checks passed
x15sr71 pushed a commit to x15sr71/ccextractor that referenced this pull request Dec 9, 2025
…CExtractor#1783)

Original description:

Pull Requests Description :
Added logic to detect and replace any occurrence of "--" in comments with a single "-" to ensure valid XML.
Used a bulk write ('fwrite') to efficiently handle portions of the string that don't contain invalid sequences.
Ensured that comments are written correctly without altering the original structure of the code.
Updated function 'write_spucomment' to handle the sanitization process efficiently.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants