• Show log

    Commit

  • Hash : 9c95c249
    Author : Cameron Gutman
    Date : 2021-11-08T20:01:56

    x11: Use XCheckIfEvent() instead of XNextEvent() for thread-safety
    
    A racing reader could read from our fd between SDL_IOReady()/X11_Pending()
    and our call to XNextEvent() which will cause XNextEvent() to block for
    more data. Avoid this by using XCheckIfEvent() which will never block.
    
    This also fixes a bug where we could poll() for data, even when events were
    already read and pending in the queue. Unlike the Wayland implementation,
    this isn't totally thread-safe because nothing prevents a racing reader
    from reading events into the queue between our XCheckIfEvent() and
    SDL_IOReady() calls, but I think this is the best we can do with Xlib.
    

  • Properties

  • Git HTTP https://git.kmx.io/kc3-lang/SDL.git
    Git SSH git@git.kmx.io:kc3-lang/SDL.git
    Public access ? public
    Description

    Fork of https://github.com/libsdl-org/SDL

    Users
    thodg_m kc3_lang_org thodg_w thodg_l www_kmx_io thodg
    Tags

  • README.md

  • Simple DirectMedia Layer (SDL) Version 2.0

    https://www.libsdl.org/

    Simple DirectMedia Layer is a cross-platform development library designed to provide low level access to audio, keyboard, mouse, joystick, and graphics hardware via OpenGL and Direct3D. It is used by video playback software, emulators, and popular games including Valve’s award winning catalog and many Humble Bundle games.

    More extensive documentation is available in the docs directory, starting with README.md

    Enjoy!

    Sam Lantinga (slouken@libsdl.org)