Skip to content

refactor: Add common msgpack array packer with callback.#2577

Merged
iphydf merged 1 commit intoTokTok:masterfrom
iphydf:obj-array
Jan 18, 2024
Merged

refactor: Add common msgpack array packer with callback.#2577
iphydf merged 1 commit intoTokTok:masterfrom
iphydf:obj-array

Conversation

@iphydf
Copy link
Copy Markdown
Member

@iphydf iphydf commented Jan 16, 2024

There will be more object arrays that need to be packed. This function
takes care of NULL (creating an empty array), and putting the correct
array size and calling the per-element callback the right amount of
times.


This change is Reviewable

@iphydf iphydf added this to the v0.2.19 milestone Jan 16, 2024
@iphydf iphydf marked this pull request as ready for review January 16, 2024 23:14
@codecov
Copy link
Copy Markdown

codecov bot commented Jan 16, 2024

Codecov Report

Attention: 36 lines in your changes are missing coverage. Please review.

Comparison is base (3c659f5) 66.85% compared to head (bdd42b5) 66.80%.

Files Patch % Lines
toxcore/tox_event.c 66.00% 17 Missing ⚠️
toxcore/bin_pack.c 77.77% 2 Missing ⚠️
toxcore/events/group_custom_packet.c 0.00% 1 Missing ⚠️
toxcore/events/group_custom_private_packet.c 0.00% 1 Missing ⚠️
toxcore/events/group_invite.c 0.00% 1 Missing ⚠️
toxcore/events/group_join_fail.c 0.00% 1 Missing ⚠️
toxcore/events/group_message.c 0.00% 1 Missing ⚠️
toxcore/events/group_moderation.c 0.00% 1 Missing ⚠️
toxcore/events/group_password.c 0.00% 1 Missing ⚠️
toxcore/events/group_peer_join.c 0.00% 1 Missing ⚠️
... and 9 more
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2577      +/-   ##
==========================================
- Coverage   66.85%   66.80%   -0.05%     
==========================================
  Files         148      148              
  Lines       30330    30376      +46     
==========================================
+ Hits        20276    20294      +18     
- Misses      10054    10082      +28     

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

@iphydf iphydf force-pushed the obj-array branch 5 times, most recently from bb4f824 to ee8615b Compare January 17, 2024 18:35
Copy link
Copy Markdown
Member

@Green-Sky Green-Sky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

update friend_request event, then this looks good to merge.

@iphydf iphydf force-pushed the obj-array branch 2 times, most recently from f7df28d to d595e18 Compare January 18, 2024 13:07
There will be more object arrays that need to be packed. This function
takes care of NULL (creating an empty array), and putting the correct
array size and calling the per-element callback the right amount of
times.
Copy link
Copy Markdown
Member

@JFreegman JFreegman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 42 of 44 files at r1, 3 of 3 files at r2, all commit messages.
Reviewable status: :shipit: complete! 1 of 1 approvals obtained

@iphydf iphydf merged commit bdd42b5 into TokTok:master Jan 18, 2024
@iphydf iphydf deleted the obj-array branch January 18, 2024 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants