[PR #1512] [CLOSED] [FIX] ccx_encoders_smptett.c: split float into ints for sprintf #2238

Closed
opened 2026-01-29 17:21:04 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/CCExtractor/ccextractor/pull/1512
Author: @marcybelardo
Created: 3/22/2023
Status: Closed

Base: masterHead: sprintf-enforce-int


📝 Commits (10+)

  • a0000f6 ccx_encoders_smptett.c: Enforce int for sprintf
  • b2e309a Added entry to changelog
  • 3d3e365 Changed spaces to tabs, following formatting
  • 1a5b5e1 Ran clang-format
  • b2f2f85 Remove decimal places from tts:origin formatting
  • ab17d08 Formatted whitespace
  • 5eae936 Too many parentheses around the round functions
  • 2addaf5 Retain precision with changed sprintf
  • cc051cc Split float to avoid locale issues with sprintf
  • 3bcd7ab Restore decimal precision to 3 digits

📊 Changes

2 files changed (+17 additions, -1 deletions)

View changed files

📝 docs/CHANGES.TXT (+1 -0)
📝 src/lib_ccx/ccx_encoders_smptett.c (+16 -1)

📄 Description

In raising this pull request, I confirm the following (please check boxes):

  • I have read and understood the contributors guide.
  • I have checked that another pull request for this purpose does not exist.
  • I have considered, and confirmed that this submission will be valuable to others.
  • I accept that this submission may not be used, and the pull request closed at the will of the maintainer.
  • I give this submission freely, and claim no ownership to its content.
  • I have mentioned this change in the changelog.

My familiarity with the project is as follows (check one):

  • I have never used CCExtractor.
  • I have used CCExtractor just a couple of times.
  • I absolutely love CCExtractor, but have not contributed previously.
  • I am an active contributor to CCExtractor.

For issue #1483, refactors formatting of col1 and row1 variables to avoid issues with LC_NUMERIC auto-formatting float values.

Decided to use %03u to keep precision at 3 digits, used %03u over %.3u for better code readability in the format string.


🔄 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/1512 **Author:** [@marcybelardo](https://github.com/marcybelardo) **Created:** 3/22/2023 **Status:** ❌ Closed **Base:** `master` ← **Head:** `sprintf-enforce-int` --- ### 📝 Commits (10+) - [`a0000f6`](https://github.com/CCExtractor/ccextractor/commit/a0000f6464896ece84b04cd37671eb89503db0bd) ccx_encoders_smptett.c: Enforce int for sprintf - [`b2e309a`](https://github.com/CCExtractor/ccextractor/commit/b2e309ada2f6ea1c2d4b9fb7ff2b3876181b4a69) Added entry to changelog - [`3d3e365`](https://github.com/CCExtractor/ccextractor/commit/3d3e365563e641ee6ebf48828e3af1378a02a818) Changed spaces to tabs, following formatting - [`1a5b5e1`](https://github.com/CCExtractor/ccextractor/commit/1a5b5e1bc1a72a53618ae6a6b32056ca4cd5c7cd) Ran clang-format - [`b2f2f85`](https://github.com/CCExtractor/ccextractor/commit/b2f2f85f48b77576eab58b5e78aeb29df279c003) Remove decimal places from tts:origin formatting - [`ab17d08`](https://github.com/CCExtractor/ccextractor/commit/ab17d080d28e051520228c2ac6a5c7a526637cac) Formatted whitespace - [`5eae936`](https://github.com/CCExtractor/ccextractor/commit/5eae9364cffef1e901f0305e0dbe51243b546258) Too many parentheses around the round functions - [`2addaf5`](https://github.com/CCExtractor/ccextractor/commit/2addaf53951376b562f3ebfd18451a49dab5db97) Retain precision with changed sprintf - [`cc051cc`](https://github.com/CCExtractor/ccextractor/commit/cc051cc3133ff61ef5fa0cd9e250f6dc735736ba) Split float to avoid locale issues with sprintf - [`3bcd7ab`](https://github.com/CCExtractor/ccextractor/commit/3bcd7ab2afa8950ceb8c50a5185f97234bd3514d) Restore decimal precision to 3 digits ### 📊 Changes **2 files changed** (+17 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `docs/CHANGES.TXT` (+1 -0) 📝 `src/lib_ccx/ccx_encoders_smptett.c` (+16 -1) </details> ### 📄 Description <!-- Please prefix your pull request with one of the following: **[FEATURE]** **[FIX]** **[IMPROVEMENT]**. --> **In raising this pull request, I confirm the following (please check boxes):** - [x] I have read and understood the [contributors guide](https://github.com/CCExtractor/ccextractor/blob/master/.github/CONTRIBUTING.md). - [x] I have checked that another pull request for this purpose does not exist. - [x] I have considered, and confirmed that this submission will be valuable to others. - [x] I accept that this submission may not be used, and the pull request closed at the will of the maintainer. - [x] I give this submission freely, and claim no ownership to its content. - [x] **I have mentioned this change in the [changelog](https://github.com/CCExtractor/ccextractor/blob/master/docs/CHANGES.TXT).** **My familiarity with the project is as follows (check one):** - [ ] I have never used CCExtractor. - [x] I have used CCExtractor just a couple of times. - [ ] I absolutely love CCExtractor, but have not contributed previously. - [ ] I am an active contributor to CCExtractor. --- For issue #1483, refactors formatting of `col1` and `row1` variables to avoid issues with `LC_NUMERIC` auto-formatting float values. Decided to use `%03u` to keep precision at 3 digits, used `%03u` over `%.3u` for better code readability in the format string. --- <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:21:05 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/ccextractor#2238