Problem investigating a heap-use-after-free in kwindowsystem

Martin Graesslin mgraesslin at
Fri Oct 2 21:24:00 BST 2015

Hi all,

I added a new unit test to kwin today [1] and it failed on the CI system due 
to the enabled ASAN with an error in kwindowsystem. I'm able to reproduce it 
locally, but fail to understand it. To me the code and the test conditions 
looks correct. Relevant part of the bt:
#0 0x7f5198ac2c84 in strncpy (/usr/lib/x86_64-linux-gnu/
    #1 0x7f5190b2be24 in nstrndup /home/martin/src/kf5/frameworks/
    #2 0x7f5190b425ff in NETRootInfo::update(QFlags<NET::Property>, 
QFlags<NET::Property2>) /home/martin/src/kf5/frameworks/kwindowsystem/src/
    #3 0x7f5190b2f8bf in NETRootInfo::activate() /home/martin/src/kf5/
    #4 0x7f519852be87 in KWin::VirtualDesktopManager::load() /home/martin/src/

Full backtrace in [2]. The content of the list names is according to qDebug: 
("Desktop 1"). From trying with qdebug it seems to fail in the first iteration 
of the for loop.

Any help appreciated to get that fixed more than appreciated (I like my tests 
green ;-) ).


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: This is a digitally signed message part.
URL: <>

More information about the kde-core-devel mailing list