Skip to content

Switch Fw::Buffer size to FwSizeType instead of U32#3802

Merged
LeStarch merged 6 commits intonasa:develfrom
thomas-bc:consistency/buffer-size-type
Jun 26, 2025
Merged

Switch Fw::Buffer size to FwSizeType instead of U32#3802
LeStarch merged 6 commits intonasa:develfrom
thomas-bc:consistency/buffer-size-type

Conversation

@thomas-bc
Copy link
Collaborator

Related Issue(s)
Has Unit Tests (y/n)
Documentation Included (y/n)

Change Description

Fix #3782

::memcpy(new_allocation.getData(), buffer.getData(), buffer.getSize());
FW_ASSERT(buffer.getSize() <= std::numeric_limits<size_t>::max(),
static_cast<FwAssertArgType>(buffer.getSize()));
::memcpy(new_allocation.getData(), buffer.getData(), static_cast<size_t>(buffer.getSize()));

Check warning

Code scanning / CodeQL

Unchecked return value Warning

The return value of non-void function
memcpy
is not checked.
@thomas-bc thomas-bc requested a review from LeStarch June 25, 2025 21:33
@LeStarch LeStarch merged commit 0a9c057 into nasa:devel Jun 26, 2025
51 checks passed
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.

Fw::Buffer size should use FwSizeType instead of U32

2 participants