Harden malloc_aligned_4k (overflow guard + quiet failure)#75
Open
k8ika0s wants to merge 1 commit into
Open
Conversation
What: Add overflow guards in malloc_aligned_4k() and avoid printing to stderr on allocation failures. Why: Overflow in size calculations is a memory-safety risk; stderr output from a library is hostile to integrators. Expected impact: Deterministic NULL returns for overflow sizes and cleaner integration logs. Tests: cover overflow guard + quiet-failure semantics (tests/testDriver_malloc4k.c). Signed-off-by: Kaitlyn Davis <k8ika0s@gmail.com> Signed-off-by: Kaitlyn Davis <kaitlyn.davis@ibm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #45
Summary
malloc_aligned_4k(overflow guard + quiet failure).Why
malloc_aligned_4k(Overflow Guard + Quiet Failure) #45 for the full problem statement, justification, and acceptance criteria.Changes
qe/issue-06-malloc4k-hardening.Validation
artifacts/final-validation-20260212T173158Z.Notes