Closed slembcke closed 2 years ago
Isn't this what's known as most-vexing parse?
Hi @slembcke, I think your change, as @iamOgunyinka said, might be converting the calling of os::X11
constructor to create x11
instance, to a function definition (so the instance is not created, and maybe the ctor/dtor not even called).
I've pushed a possible fix here. Initializing the m_xi pointer (the pointer inside XInput
class) correctly. Could you check if this fix your problem?
That commit seems to fix the issue as well. Thanks!
(edit: irrelevant C++ joke removed)
Running Aseprite batch mode (using
-b
) as part of a headless asset build process was causing it to segfault inXInput::~XInput()
becausem_xi
was uninitialized. Forcing zero initialization fixes it.I agree that my contributions are licensed under the Laf license, and agree to future changes to the licensing.