---
name: "SDL_GetNumAllocations"
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_GetNumAllocations"
---

# SDL\_GetNumAllocations(3)

Get the number of outstanding (unfreed) allocations.

## NAME

SDL\_GetNumAllocations - Get the number of outstanding (unfreed) allocations.

## HEADER FILE

Defined in SDL3/SDL\_stdinc.h

## SYNOPSIS

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

**int SDL\_GetNumAllocations(void);**

## RETURN VALUE

Returns the number of allocations or -1 if allocation counting is disabled.

## THREAD SAFETY

It is safe to call this function from any thread.

## AVAILABILITY

This function is available since SDL 3.2.0.
