Function

Vipstracked_aligned_alloc

Declaration [src]

void*
vips_tracked_aligned_alloc (
  size_t size,
  size_t align
)

Description [src]

Allocate an area of memory aligned on a boundary specified by align that will be tracked by vips_tracked_get_mem() and friends.

If allocation fails, vips_tracked_aligned_alloc() returns NULL and sets an error message.

You must only free the memory returned with vips_tracked_aligned_free().

Parameters

size

Type: size_t

Number of bytes to allocate.

align

Type: size_t

Specifies the alignment.

Return value

Type: void*

A pointer to the allocated memory, or NULL on error.

The caller of the function takes ownership of the data, and is responsible for freeing it.
The return value can be NULL.