SDL_CloseStorage(3)

πŸ’– SDL_CloseStorage(3) πŸ’–

okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual, where today's main character is SDL_CloseStorage πŸ’…


✨ NAME ✨

SDL_CloseStorage β€” closes and frees a storage container. that's it, that's the whole job. she opens, she closes, she frees, she leaves no crumbs πŸŽ€


🌸 SYNOPSIS 🌸

#include <SDL3/SDL_storage.h>

bool SDL_CloseStorage(SDL_Storage *storage);

πŸ¦‹ FUNCTION PARAMETERS πŸ¦‹

  • storage β€” a storage container to close. like, the one you want to shut down. hand her over 🫢

⭐ RETURN VALUE ⭐

Returns true if the container was freed with no errors, and false otherwise. if you got false, go call SDL_GetError() for more information, she'll tell you what went down πŸ‘‘

and listen, this part is important so i'm gonna say it loud: even if the function returns an error, the container data will be freed. the error is only for informational purposes. so like, the vibe is "she did the thing, but she's also telling you about it." no leaks, just receipts πŸ’€


πŸ‘‘ AVAILABILITY πŸ‘‘

This function is available since SDL 3.2.0. if your SDL is older than that, no she isn't, bestie 😭


🌈 SEE ALSO 🌈

like, the whole open-and-close friend group. you can't close if you never opened, iykyk ✨


Simple Directmedia Layer Β· SDL 3.4.18 Β· SDL_CloseStorage(3)

that's the page, that's the energy, go free your storage containers responsibly πŸ’–πŸ§šβ€β™€οΈ

πŸ“¦ where this page comes from