Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/m/memalign.html on line 1
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/m/memalign.html on line 1
Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/m/memalign.html on line 8
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/m/memalign.html on line 8
Allocate aligned memory
#include <malloc.h>
void *memalign( size_t alignment,
size_t size );
- alignment
- The alignment that you want to use for the memory.
This must be a multiple of size( void *).
- size
- The amount of memory you want to allocate, in bytes.
libc
Use the -l c option to
qcc
to link against this library.
This library is usually included automatically.
The memalign() function allocates size bytes aligned on
a boundary specified by alignment.
A pointer to the allocated block, or NULL if an error occurred
(errno
is set).
- EINVAL
- The value of alignment isn't a multiple of
size( void *).
- ENOMEM
- There's insufficient memory available with the requested alignment.
QNX Neutrino
Safety: | |
Cancellation point |
No |
Interrupt handler |
No |
Signal handler |
Yes |
Thread |
Yes |
free(),
malloc(),
posix_memalign()
Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/m/memalign.html on line 132
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/m/memalign.html on line 132