Scroll to navigation

SDL_GetErrorMsg(3) SDL3 FUNCTIONS SDL_GetErrorMsg(3)

NAME

SDL_GetErrorMsg - Get the last error message that was set for the current thread.

SYNOPSIS

#include "SDL3/SDL.h"
char * SDL_GetErrorMsg(char *errstr, int maxlen);

DESCRIPTION

This allows the caller to copy the error string into a provided buffer, but otherwise operates exactly the same as SDL_GetError ().

FUNCTION PARAMETERS

A buffer to fill with the last error message that was set for the current thread
The size of the buffer pointed to by the errstr parameter

RETURN VALUE

Returns the pointer passed in as the errstr parameter.

AVAILABILITY

This function is available since SDL 3.0.0.

SEE ALSO

SDL_GetError(3)

SDL 3.0.0 SDL