svn commit: r235780 - head/include
Hartmut Brandt
harti at FreeBSD.org
Tue May 22 09:59:50 UTC 2012
Author: harti
Date: Tue May 22 09:59:49 2012
New Revision: 235780
URL: http://svn.freebsd.org/changeset/base/235780
Log:
Fix a compilation error with some compilers: __attribute__
requires two parenthesis for its argument, but instead of using
__attribute__ directly, use the appropriate __nonnull macro
from cdefs.h.
Modified:
head/include/malloc_np.h
Modified: head/include/malloc_np.h
==============================================================================
--- head/include/malloc_np.h Tue May 22 09:27:57 2012 (r235779)
+++ head/include/malloc_np.h Tue May 22 09:59:49 2012 (r235780)
@@ -55,13 +55,11 @@ int mallctlbymib(const size_t *mib, size
#define ALLOCM_ERR_OOM 1
#define ALLOCM_ERR_NOT_MOVED 2
-int allocm(void **ptr, size_t *rsize, size_t size, int flags)
- __attribute__(nonnull(1));
+int allocm(void **ptr, size_t *rsize, size_t size, int flags) __nonnull(1);
int rallocm(void **ptr, size_t *rsize, size_t size, size_t extra,
- int flags) __attribute__(nonnull(1));
-int sallocm(const void *ptr, size_t *rsize, int flags)
- __attribute__(nonnull(1));
-int dallocm(void *ptr, int flags) __attribute__(nonnull(1));
+ int flags) __nonnull(1);
+int sallocm(const void *ptr, size_t *rsize, int flags) __nonnull(1);
+int dallocm(void *ptr, int flags) __nonnull(1);
int nallocm(size_t *rsize, size_t size, int flags);
__END_DECLS
More information about the svn-src-head
mailing list