Amiberry input "leaks" to the console (SDL2 bug?)

When you run the Amiberry Amiga emulator and type something into the emulator, the keyboard input “leaks” to the console. So when you exit the emulator, the Linux console is full of all the characters you entered during the emulation session.

From earlier posts on the net, it looks like this is a bug with SDL2 and was fixed in 2.0.6 and newer. Any chance of getting this fixed with DietPi?

I’m running DietPi 6.6 fully updated, on a Pi 3b+, and Amiberry is set to autostart (normal boot).

Edit: It seems sometimes it doesn’t leak when using Fast boot. Sometimes it does, but since it doesn’t actually log in to the terminal, it never does any harm.

Also, sometimes when exiting Amiberry, I’m not able to log in or input anything into the first terminal. I have to switch to another tty (ctrl+alt+f2) to be able to log in.