This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug malloc/20137] New: aligned_alloc should fail for bad size / alignment [DR#460]
- From: "jsm28 at gcc dot gnu.org" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Tue, 24 May 2016 12:02:50 +0000
- Subject: [Bug malloc/20137] New: aligned_alloc should fail for bad size / alignment [DR#460]
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=20137
Bug ID: 20137
Summary: aligned_alloc should fail for bad size / alignment
[DR#460]
Product: glibc
Version: 2.23
Status: NEW
Severity: normal
Priority: P2
Component: malloc
Assignee: unassigned at sourceware dot org
Reporter: jsm28 at gcc dot gnu.org
Target Milestone: ---
The resolution to C11 DR#460 requires aligned_alloc to return NULL if the
alignment is not valid (not a power of 2, in our case) or the size is not a
multiple of the alignment. This needs to be implemented.
For compatibility with existing binaries, I think we should have a compat
symbol for aligned_alloc that remains as an alias to memalign (whose semantics
should remain unchanged), and implement the stricter semantics only at a new
symbol version.
--
You are receiving this mail because:
You are on the CC list for the bug.