SDL2 and Codelite GDB
Linux Mint
AMD
AMD GPU
There has been then bug where when after running GDB to debug a SDL2 application my window manger stops working correctly or I get blank SDL2 windows. I finally narrowed down to Codelite its self.
I originally thought it was compiz but after trying on KDE and seeing the same bug I was just amazed.
When it does NOT happen:
- If XFCE is doing the window composition aka no 3d this bug does not happen. I like wobbly windows to much.
- If running GDB under clion this bug does NOT happen.
- Also does not happen under nvim, this was hard to test...
- If running LLDB debugger under codelite it also does NOT happen.
- If just running GDB from the command line it doe NOT happen.
It seems like Codelite is interfering with SDL2 somehow when initializing the window when debugging under GDB.
How to reproduce (one of the most annoying bugs to reproduce)
- It will not happen right away, you have to keep rerunning the debugger for about 20 minutes. (just hit f5 over and over) This would be same as developing something for a few days.
- The source code: https://lazyfoo.net/tutorials/SDL/07_te ... /index.php
- Just keep running and eventually a blank window will appear or no window. and when you try to debug it again it will work for awhile then after a few more debugs it will not but once you hit this first occurrence it seems to be easier to reporduce.
This is a very annoying bug because it crashed KDE and Compiz will eventually become non functioning but handles it better than KDE.