[uclibc-ng-devel] [PATCH] valloc declaration in stdlib.h

Eugene Yudin e.yudin at ndmsystems.com
Mon Jul 24 16:04:17 CEST 2017


Hi,

Current uClibc-ng have issue with several different valloc declarations.

malloc.h:
#ifdef __UCLIBC_SUSV2_LEGACY__
/* Allocate SIZE bytes on a page boundary.  */
extern __malloc_ptr_t valloc __MALLOC_P ((size_t __size))
__attribute_malloc__;
#endif

stdlib.h:
 #if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
 /* Allocate SIZE bytes on a page boundary.  The storage cannot be freed.
 */
 extern void *valloc (size_t __size) __THROW __attribute_malloc__ __wur;
 #endif

The second declaration doesn't use the define __UCLIBC_SUSV2_LEGACY__.
That leads to compile time problems.

The attached patch fixes this diffrence.

-- 
Best regards,
Eugene
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.uclibc-ng.org/pipermail/devel/attachments/20170724/5b0acee9/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: stdlib_fix_valloc.patch
Type: text/x-patch
Size: 805 bytes
Desc: not available
URL: <http://mailman.uclibc-ng.org/pipermail/devel/attachments/20170724/5b0acee9/attachment.bin>


More information about the devel mailing list