Since the extension is searched in the file name only, the check for
a leading dot must compare against the file name rather than the full
path: "assets/.gitignore" returned ".gitignore" while ".gitignore"
returned NULL.
LoadImageFromMemory() passed fileData[12] (the channels byte of the QOI
header) to qoi_decode() as the requested channel count, reading it before
qoi_decode() checks the data size. Data shorter than 13 bytes made it read
past the end of the buffer.
Pass 0 instead, so qoi_decode() uses the channel count from the header after
checking the size. For valid files this gives the same result, since the
value passed was that same header byte.
gestureLogIndex started at GESTURE_LOG_SIZE, and the log drawing loop
starts reading at that index, so gestureLog[GESTURE_LOG_SIZE] (one past
the end) was read every frame until the first gesture was logged.
Start the index at 0 instead. Logging is unchanged: the first logged
gesture still wraps to GESTURE_LOG_SIZE - 1.
The waveform loop draws a line from sample i to sample i + 1 for every
x in [0, screenWidth). For the last x, the end point index works out to
SAMPLE_RATE, one past the end of buffer[SAMPLE_RATE]. Stop the loop one
pixel earlier so the last segment ends on the final sample.
If the source sound failed to load (for example when no audio
playback device could be initialized), its stream.buffer is NULL and
LoadSoundAlias() dereferenced it. Check the buffer first, like
UnloadSoundAlias() and IsSoundValid() already do, so an empty Sound
is returned instead of crashing.
Seen with examples/audio/audio_sound_multi (reported in #5664).
If resources/models/gltf/robot.glb can't be found (e.g. the example is
run from another working directory), LoadModelAnimations() returns NULL
with animCount = 0 and the example indexed anims[] in the update loop
and in the timeline drawing, crashing. Skip both when no animations
were loaded, so it just logs the usual load warnings.
Reported in #5664.