---
name: "SDL_CondWait"
section: "3"
platform: "linux"
package: "libsdl1.2-dev"
version: "1.2.15+dfsg2-8"
release: "Debian 12 (Bookworm)"
platforms: ["linux"]
url: "https://new.carta.tech/SDL_CondWait"
---

# SDL\_CondWait(3)

Wait on a condition variable

## NAME

SDL\_CondWait - Wait on a condition variable

## SYNOPSIS

**#include "SDL.h"** **#include "SDL\_thread.h"**

**int SDL\_CondWait**(**SDL\_cond \*cond, SDL\_mutex \*mut**);

## DESCRIPTION

Wait on the condition variable **cond** and unlock the provided mutex. The mutex must the locked before entering this function. Returns **0** when it is signalled, or **-1** on an error.

## SEE ALSO

**SDL\_CondWaitTimeout**, **SDL\_CondSignal**, **SDL\_mutexP**
