Skip to content

[v2.12]refactor(json): change array length type from uint16_t to size_t#2844

Closed
ZhouBox wants to merge 2 commits into
emqx:v2.12from
ZhouBox:v2.12
Closed

[v2.12]refactor(json): change array length type from uint16_t to size_t#2844
ZhouBox wants to merge 2 commits into
emqx:v2.12from
ZhouBox:v2.12

Conversation

@ZhouBox

@ZhouBox ZhouBox commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

No description provided.

ZhouBox added 2 commits July 1, 2026 11:16
- Replace uint16_t length with size_t in all neu_json_value_array_* structs
- Fix sign-compare warnings in loop iterators (int -> size_t)
- Fix transposed calloc arguments in restful rw_handle
Comparing the array address addr.sun_path with 0 is always false.
Check sun_path[1] instead, matching the abstract socket convention
where sun_path[0] is always '\0'.
@codecov-commenter

codecov-commenter commented Jul 1, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 13.04348% with 20 lines in your changes missing coverage. Please review.
✅ Project coverage is 65.41%. Comparing base (f017a84) to head (4adf213).

Files with missing lines Patch % Lines
src/utils/json.c 6.66% 14 Missing ⚠️
plugins/restful/rw_handle.c 14.28% 6 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##            v2.12    #2844       +/-   ##
===========================================
+ Coverage   39.88%   65.41%   +25.53%     
===========================================
  Files         108      121       +13     
  Lines       23228    27808     +4580     
===========================================
+ Hits         9264    18191     +8927     
+ Misses      13964     9617     -4347     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ZhouBox ZhouBox closed this Jul 1, 2026
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.

2 participants