Skip to content

Consider option that malloc(0) may return NULL #1777

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Jul 9, 2025
Merged

Conversation

michael-schwarz
Copy link
Member

@michael-schwarz michael-schwarz commented Jul 3, 2025

  • Adds an option to configure behavior when allocating 0 bytes in line with C99 draft, 7.20.3 (1)
  • Replace bool to indicate whether allocation is on heap or stack with variant type
  • Introduce more sharing in base analysis between allocating functions in special.

Closes #1418

@michael-schwarz michael-schwarz added this to the v2.6.0 milestone Jul 3, 2025
@sim642 sim642 mentioned this pull request Jul 7, 2025
1 task
@michael-schwarz michael-schwarz requested a review from sim642 July 8, 2025 10:58
@michael-schwarz michael-schwarz merged commit f2c4520 into master Jul 9, 2025
19 checks passed
@michael-schwarz michael-schwarz deleted the issue_1418 branch July 9, 2025 07:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup Refactoring, clean-up feature unsound
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unsoundness for malloc(0)
2 participants