---
name: "SDL_aligned_free"
section: "3"
platform: "linux"
package: "libsdl3-doc"
version: "3.2.10+ds-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/SDL_aligned_free"
---

# SDL\_aligned\_free(3)

Free memory allocated by SDL\_aligned\_alloc ().

## NAME

SDL\_aligned\_free - Free memory allocated by  **SDL\_aligned\_alloc** ().

## HEADER FILE

Defined in SDL3/SDL\_stdinc.h

## SYNOPSIS

```
#include "SDL3/SDL.h"
```

**void SDL\_aligned\_free(void \*mem);**

## DESCRIPTION

The pointer is no longer valid after this call and cannot be dereferenced anymore.

If **mem** is NULL, this function does nothing.

## FUNCTION PARAMETERS

- *mem*

  a pointer previously returned by  **SDL\_aligned\_alloc** (), or NULL.

## THREAD SAFETY

It is safe to call this function from any thread.

## AVAILABILITY

This function is available since SDL 3.2.0.

## SEE ALSO

**•**(3), [**SDL\_aligned\_alloc**(3)](/SDL_aligned_alloc/3.md)
