logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

SDL_strlen - This works exactly like strlen() but doesn't require access to a C runtime.

Availability

       This function is available since SDL 3.2.0.

Description

       Counts the bytes in str, excluding the null terminator.

       If you need the length of a UTF-8 string, consider using SDL_utf8strlen().

Function Parameters

str    The null-terminated string to read. Must not be NULL.

Name

       SDL_strlen - This works exactly like strlen() but doesn't require access to a C runtime.

Return Value

       Returns the length (in bytes, excluding the null terminator) of src.

See Also

SDL_strnlen(3), SDL_utf8strlen(3), SDL_utf8strnlen(3)

Simple Directmedia Layer                           SDL 3.2.20                                      SDL_strlen(3)

Synopsis

#include<SDL3/SDL_stdinc.h>size_tSDL_strlen(constchar*str);

Thread Safety

       It is safe to call this function from any thread.

See Also