[PR #1783] [MERGED] [FIX] Handle double-hyphens in XML comments in spupng encoder #2509

Open
opened 2026-01-29 17:22:31 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/CCExtractor/ccextractor/pull/1783
Author: @cfsmp3
Created: 12/8/2025
Status: Merged
Merged: 12/8/2025
Merged by: @cfsmp3

Base: masterHead: pr-1642-rebase


📝 Commits (1)

  • e9ef9ad Fix Issue#1235: Sanitize XML comment to prevent invalid token errors

📊 Changes

1 file changed (+32 additions, -1 deletions)

View changed files

📝 src/lib_ccx/ccx_encoders_spupng.c (+32 -1)

📄 Description

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


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/CCExtractor/ccextractor/pull/1783 **Author:** [@cfsmp3](https://github.com/cfsmp3) **Created:** 12/8/2025 **Status:** ✅ Merged **Merged:** 12/8/2025 **Merged by:** [@cfsmp3](https://github.com/cfsmp3) **Base:** `master` ← **Head:** `pr-1642-rebase` --- ### 📝 Commits (1) - [`e9ef9ad`](https://github.com/CCExtractor/ccextractor/commit/e9ef9ad9017d4035aa6ba9ba93e980a08e9ee278) Fix Issue#1235: Sanitize XML comment to prevent invalid token errors ### 📊 Changes **1 file changed** (+32 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `src/lib_ccx/ccx_encoders_spupng.c` (+32 -1) </details> ### 📄 Description ## 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](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-29 17:22:31 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/ccextractor#2509