[PR #1199] [MERGED] [IMPROVEMENT] Remove warning when calling paraof_ocrtext #1993

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

📋 Pull Request Information

Original PR: https://github.com/CCExtractor/ccextractor/pull/1199
Author: @NilsIrl
Created: 1/19/2020
Status: Merged
Merged: 1/20/2020
Merged by: @cfsmp3

Base: masterHead: warning_4


📝 Commits (1)

  • 0fd969e Remove warning when calling paraof_ocrtext

📊 Changes

2 files changed (+3 additions, -3 deletions)

View changed files

📝 src/lib_ccx/ocr.c (+2 -2)
📝 src/lib_ccx/ocr.h (+1 -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.

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

  • I have used CCExtractor just a couple of times.

Removes warnings:

0a1
> Scanning dependencies of target ccx
550,558d550
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_splitbysentence.c:765:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign]
<   765 |  str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length);
<       |                            ~~~~~~~^~~~~~~~~~~~~~
<       |                                   |
<       |                                   unsigned char *
< In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_splitbysentence.c:18:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’
<    19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length);
<       |       ^~~~~~~~~~~~~~
571,580d562
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_spupng.c: In function ‘write_cc_bitmap_as_spupng’:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_spupng.c:452:36: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign]
<   452 |   str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length);
<       |                             ~~~~~~~^~~~~~~~~~~~~~
<       |                                    |
<       |                                    unsigned char *
< In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_spupng.c:12:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’
<    19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length);
<       |       ^~~~~~~~~~~~~~
620,629d601
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_srt.c: In function ‘write_cc_bitmap_as_srt’:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_srt.c:100:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign]
<   100 |  str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length);
<       |                            ~~~~~~~^~~~~~~~~~~~~~
<       |                                   |
<       |                                   unsigned char *
< In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_srt.c:6:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’
<    19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length);
<       |       ^~~~~~~~~~~~~~
679,688d650
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_ssa.c: In function ‘write_cc_bitmap_as_ssa’:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_ssa.c:94:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign]
<    94 |  str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length);
<       |                            ~~~~~~~^~~~~~~~~~~~~~
<       |                                   |
<       |                                   unsigned char *
< In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_ssa.c:6:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’
<    19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length);
<       |       ^~~~~~~~~~~~~~
730,738d691
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_transcript.c:35:39: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign]
<    35 |    token = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length);
<       |                                ~~~~~~~^~~~~~~~~~~~~~
<       |                                       |
<       |                                       unsigned char *
< In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_transcript.c:4:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’
<    19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length);
<       |       ^~~~~~~~~~~~~~
754,763d706
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_webvtt.c: In function ‘write_cc_bitmap_as_webvtt’:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_webvtt.c:287:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign]
<   287 |  str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length);
<       |                            ~~~~~~~^~~~~~~~~~~~~~
<       |                                   |
<       |                                   unsigned char *
< In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_webvtt.c:6:
< /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’
<    19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length);
<       |       ^~~~~~~~~~~~~~

🔄 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/1199 **Author:** [@NilsIrl](https://github.com/NilsIrl) **Created:** 1/19/2020 **Status:** ✅ Merged **Merged:** 1/20/2020 **Merged by:** [@cfsmp3](https://github.com/cfsmp3) **Base:** `master` ← **Head:** `warning_4` --- ### 📝 Commits (1) - [`0fd969e`](https://github.com/CCExtractor/ccextractor/commit/0fd969e94b51859349def242a501eecc10987ffb) Remove warning when calling paraof_ocrtext ### 📊 Changes **2 files changed** (+3 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `src/lib_ccx/ocr.c` (+2 -2) 📝 `src/lib_ccx/ocr.h` (+1 -1) </details> ### 📄 Description **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. **My familiarity with the project is as follows (check one):** - [X] I have used CCExtractor just a couple of times. --- Removes warnings: ```patch 0a1 > Scanning dependencies of target ccx 550,558d550 < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_splitbysentence.c:765:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign] < 765 | str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length); < | ~~~~~~~^~~~~~~~~~~~~~ < | | < | unsigned char * < In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_splitbysentence.c:18: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ < 19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length); < | ^~~~~~~~~~~~~~ 571,580d562 < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_spupng.c: In function ‘write_cc_bitmap_as_spupng’: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_spupng.c:452:36: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign] < 452 | str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length); < | ~~~~~~~^~~~~~~~~~~~~~ < | | < | unsigned char * < In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_spupng.c:12: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ < 19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length); < | ^~~~~~~~~~~~~~ 620,629d601 < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_srt.c: In function ‘write_cc_bitmap_as_srt’: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_srt.c:100:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign] < 100 | str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length); < | ~~~~~~~^~~~~~~~~~~~~~ < | | < | unsigned char * < In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_srt.c:6: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ < 19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length); < | ^~~~~~~~~~~~~~ 679,688d650 < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_ssa.c: In function ‘write_cc_bitmap_as_ssa’: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_ssa.c:94:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign] < 94 | str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length); < | ~~~~~~~^~~~~~~~~~~~~~ < | | < | unsigned char * < In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_ssa.c:6: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ < 19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length); < | ^~~~~~~~~~~~~~ 730,738d691 < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_transcript.c:35:39: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign] < 35 | token = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length); < | ~~~~~~~^~~~~~~~~~~~~~ < | | < | unsigned char * < In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_transcript.c:4: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ < 19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length); < | ^~~~~~~~~~~~~~ 754,763d706 < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_webvtt.c: In function ‘write_cc_bitmap_as_webvtt’: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_webvtt.c:287:35: warning: pointer targets in passing argument 2 of ‘paraof_ocrtext’ differ in signedness [-Wpointer-sign] < 287 | str = paraof_ocrtext(sub, context->encoded_crlf, context->encoded_crlf_length); < | ~~~~~~~^~~~~~~~~~~~~~ < | | < | unsigned char * < In file included from /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ccx_encoders_webvtt.c:6: < /home/nils/Documents/codein2019/ccextractor/src/lib_ccx/ocr.h:19:7: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ < 19 | char *paraof_ocrtext(struct cc_subtitle *sub, const char *crlf, unsigned crlf_length); < | ^~~~~~~~~~~~~~ ``` --- <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:19:37 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/ccextractor#1993