Martin Gerhardy wrote:
If there is a variable named test, then cmake does variable-value comparison:
if (test STREQUAL "")
is equivalent to:
if ("${test}" STREQUAL "")
If there is no variable named test, then cmake does string literal comparison:
if (test STREQUAL "")
is equivalent to:
if ("test" STREQUAL "")
That means basically - the current stuff works - but is not how it should be done.
Fixes https://github.com/libsdl-org/SDL/issues/2100
SDL_Init(SDL_INIT_AUDIO) did not take into account that functions like
SDL_AddAudioDevice do register events, which will need final cleanup
and only gets fired when events were actually initialised.
Sample call stack of a malloc missing its free (Linux + PA):
SDL_malloc_REAL (SDL_malloc.c:5328)
SDL_AddEvent (SDL_events.c:445)
SDL_PeepEvents_REAL (SDL_events.c:531)
SDL_PushEvent_REAL (SDL_events.c:762)
SDL_AddAudioDevice (SDL_audio.c:443)
SourceInfoCallback (SDL_pulseaudio.c:681)
context_get_source_info_callback (introspect.c:534)
run_action (pdispatch.c:288)
pa_pdispatch_run (pdispatch.c:341)
pstream_packet_callback (context.c:349)
do_read (pstream.c:1012)
Fixes https://github.com/libsdl-org/SDL/issues/3005
When mouse buttons are swapped, right mouse button down is the same value as raw mouse button up, and conceptually the two systems use different button masks, so never cache state between the two.
Fixes https://github.com/libsdl-org/SDL/issues/5108
Program received signal SIGILL, Illegal instruction.
X11_InitKeyboard (_this=0x1001f8f0)
at /home/sdl/SDL_git/src/video/x11/SDL_x11keyboard.c:273
273 XKeyboardState values = { .global_auto_repeat = AutoRepeatModeOff };
If the X server's byte order is different from the client, things might
display in the wrong colour.
Apparently we can just set the byte_order field to the client's byte
order, and the X server will adjust everything automatically:
https://xorg.freedesktop.narkive.com/GbSD1aPq/ximage-s-byte-order-field