fix sign-compare compiler warning

Review Request #2284 — Created Feb. 24, 2023 and discarded

Information

talkatu/talkatu
default

Reviewers

fix sign-compare compiler warning

Built scan-build target which found no errors.

Summary ID
fix sign-compare compiler warning
6b29e6af849c994885a1745bc47625aa2cb27b34
Description From Last Updated

g_convert takes a gssize and returns a gsize, as does g_utf8_validate. I wonder if we should be doing the same. …

QuLogicQuLogic
QuLogic
  1. 
      
  2. Show all issues

    g_convert takes a gssize and returns a gsize, as does g_utf8_validate. I wonder if we should be doing the same. Also, if we should be passing length to g_utf8_validate instead of -1.

    1. oh wow I never noticed the gssize vs gsize thing before.. But yeah we should probably be doing that.

    2. For me, that's not really within the scope of this review request. I wouldn't feel comfortable doing these changes without testing them and by the looks of it there's no code actually executing talkatu_codeset_coerce_utf8. It's called by talkatu_markdown_buffer_deserialize_markdown and talkatu_markup_deserialize_html but those again are not used anywhere. So some unit tests would need to be created. I'm sorry but I can't put in that amount of work right now.

    3. Yeah no worries, I'll take care of it and discard this review request. Sorry you went through the effort, I should have looked at it more closely :-/

  3. 
      
grim
Review request changed
Status:
Discarded
Change Summary:

we're going to rework the way these functions work