[Bug 269688] memalign() produces division by zero if alignment is 0
- In reply to: bugzilla-noreply_a_freebsd.org: "[Bug 269688] memalign() produces division by zero if size is 0"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 25 Sep 2023 04:34:59 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=269688 Paul Floyd <pjfloyd@wanadoo.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|New |Closed --- Comment #8 from Paul Floyd <pjfloyd@wanadoo.fr> --- libc: handle zero alignment in memalign() For compatibility with glibc. The previous code would trigger a division by zero in roundup() and terminate. Instead, just pass through to malloc() for align == 0. PR: 269688 Reviewed by: imp, mjg MFC after: 1 week Pull Request: #655 -- You are receiving this mail because: You are the assignee for the bug.