SDL_ClearError(3)

πŸ’– SDL_ClearError(3) πŸ’–

okay bestie, welcome to the SDL3 FUNCTIONS corner of the man pages β€” this one's a tiny little icon and honestly? it's giving "emotional reset button" ✨


🌸 NAME 🌸

SDL_ClearError β€” wipe away any previous error message for this thread. that's it. that's the whole job. no cap πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

#include <SDL3/SDL_error.h>

bool SDL_ClearError(void);

πŸ¦‹ DESCRIPTION πŸ¦‹

so like, picture this: your thread has been through some stuff 😭 and there's an old error message just... sitting there. lingering. living rent free in your error buffer. SDL_ClearError is the function that clears any previous error message for this thread. fresh start, clean slate, main character energy πŸ‘‘


⭐ RETURN VALUE ⭐

it returns true. that's the whole vibe. it just works, and it tells you so 🫢


🧚 THREAD SAFETY 🧚

it is safe to call this function from any thread. any of them. all of them. go wild, no notes 🌈


✨ AVAILABILITY ✨

this function has been available since SDL 3.2.0 β€” so if you're on anything older, bestie, it's not there, and that's just the truth πŸ™ˆ


πŸ‘‘ SEE ALSO πŸ‘‘


and that's the whole page, gorgeous πŸ’œ this was SDL_ClearError(3) from the Simple Directmedia Layer crew, SDL 3.4.18 edition, and it ate. periodt. πŸŽ€βœ¨

πŸ“¦ where this page comes from