[gcc r14-10311] libstdc++: Fix declaration of posix_memalign for freestanding
Jonathan Wakely
redi@gcc.gnu.org
Fri Jun 14 14:40:22 GMT 2024
https://gcc.gnu.org/g:75251f5091c9b81577e031ab781d42c6cbe4a64b
commit r14-10311-g75251f5091c9b81577e031ab781d42c6cbe4a64b
Author: Jonathan Wakely <jwakely@redhat.com>
Date: Fri Jun 14 12:10:48 2024 +0100
libstdc++: Fix declaration of posix_memalign for freestanding
Thanks to Jérôme Duval for noticing this.
libstdc++-v3/ChangeLog:
* libsupc++/new_opa.cc [!_GLIBCXX_HOSTED]: Fix declaration of
posix_memalign.
(cherry picked from commit 161efd677458f20d13ee1018a4d5e3964febd508)
Diff:
---
libstdc++-v3/libsupc++/new_opa.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libstdc++-v3/libsupc++/new_opa.cc b/libstdc++-v3/libsupc++/new_opa.cc
index 35606e1c1b3d..c7c7e7946239 100644
--- a/libstdc++-v3/libsupc++/new_opa.cc
+++ b/libstdc++-v3/libsupc++/new_opa.cc
@@ -47,7 +47,7 @@ using std::size_t;
extern "C"
{
# if _GLIBCXX_HAVE_POSIX_MEMALIGN
- void *posix_memalign(void **, size_t alignment, size_t size);
+ int posix_memalign(void **, size_t alignment, size_t size);
# elif _GLIBCXX_HAVE_ALIGNED_ALLOC
void *aligned_alloc(size_t alignment, size_t size);
# elif _GLIBCXX_HAVE__ALIGNED_MALLOC
More information about the Gcc-cvs
mailing list