Bug 304340 - segfault on exiting cube effect
Summary: segfault on exiting cube effect
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: effects-window-management (show other bugs)
Version: 4.9.0
Platform: OpenSUSE Linux
: NOR crash (vote)
Target Milestone: 4.9.1
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-07-31 15:30 UTC by Pedro Martin
Modified: 2012-08-11 20:34 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.9.1
thomas.luebking: ReviewRequest+


Attachments
New crash information added by DrKonqi (5.34 KB, text/plain)
2012-08-02 18:00 UTC, vinnywright
Details
kwin crash handler (4.66 KB, text/plain)
2012-08-03 16:50 UTC, Pedro Martin
Details
kwinrc (3.97 KB, application/octet-stream)
2012-08-03 18:02 UTC, Pedro Martin
Details
kwinrc in txt format (3.98 KB, text/plain)
2012-08-03 18:07 UTC, Pedro Martin
Details
New crash information added by DrKonqi (4.05 KB, text/plain)
2012-08-04 16:19 UTC, Denis M. (Phr33d0m)
Details
New crash information added by DrKonqi (5.22 KB, text/plain)
2012-08-10 09:05 UTC, Erick Osorio
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Pedro Martin 2012-07-31 15:30:50 UTC
Application: kwin (4.8.97 "release 549")
KDE Platform Version: 4.8.97 "release 549"
Qt Version: 4.8.2
Operating System: Linux 3.1.10-1.16-desktop x86_64
Distribution: "openSUSE 12.1 (x86_64)"

-- Information about the crash:
- What I was doing when the application crashed:
ctrl +F11 to see if cube is working properly. It does, but when I pushed "intro" to back to normal desktop, machine does it properly. but kwin reports  the crash. No window is closed or malfunctionning.
Reproducible always.

The crash can be reproduced every time.

-- Backtrace:
Application: KWin (kwin), signal: Segmentation fault
[Current thread is 1 (Thread 0x7fe61a1a57a0 (LWP 4696))]

Thread 2 (Thread 0x7fe5fc93d700 (LWP 4724)):
#0  0x00007fe615164e6c in pthread_cond_wait@@GLIBC_2.3.2 () from /lib64/libpthread.so.0
#1  0x00007fe616886952 in QTWTF::TCMalloc_PageHeap::scavengerThread (this=0x7fe616b7fe80) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2359
#2  0x00007fe616886989 in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=<optimized out>) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1464
#3  0x00007fe616058ae4 in ?? () from /usr/lib64/libGL.so.1
#4  0x00007fe615160f05 in start_thread () from /lib64/libpthread.so.0
#5  0x00007fe6199d010d in clone () from /lib64/libc.so.6

Thread 1 (Thread 0x7fe61a1a57a0 (LWP 4696)):
[KCrash Handler]
#6  KWin::CubeEffect::postPaintScreen (this=0xf7a780) at /usr/src/debug/kde-workspace-4.8.97/kwin/effects/cube/cube.cpp:1172
#7  0x00007fe619d5db68 in KWin::EffectsHandlerImpl::postPaintScreen (this=0x652bd0) at /usr/src/debug/kde-workspace-4.8.97/kwin/effects.cpp:250
#8  0x00007fe619d5db68 in KWin::EffectsHandlerImpl::postPaintScreen (this=0x652bd0) at /usr/src/debug/kde-workspace-4.8.97/kwin/effects.cpp:250
#9  0x00007fe619d3de2e in KWin::Scene::paintScreen (this=0x897ae0, mask=<optimized out>, region=0x7fff75656d80) at /usr/src/debug/kde-workspace-4.8.97/kwin/scene.cpp:150
#10 0x00007fe619d546ee in KWin::SceneOpenGL::paint (this=0x897ae0, damage=..., toplevels=<optimized out>) at /usr/src/debug/kde-workspace-4.8.97/kwin/scene_opengl_glx.cpp:481
#11 0x00007fe619d371c2 in performCompositing (this=0x814fe0) at /usr/src/debug/kde-workspace-4.8.97/kwin/composite.cpp:433
#12 KWin::Workspace::performCompositing (this=0x814fe0) at /usr/src/debug/kde-workspace-4.8.97/kwin/composite.cpp:397
#13 0x00007fe61550fb39 in QObject::event (this=0x814fe0, e=<optimized out>) at kernel/qobject.cpp:1166
#14 0x00007fe61465cfe4 in notify_helper (e=0x7fff75657450, receiver=0x814fe0, this=0x6acd70) at kernel/qapplication.cpp:4551
#15 QApplicationPrivate::notify_helper (this=0x6acd70, receiver=0x814fe0, e=0x7fff75657450) at kernel/qapplication.cpp:4523
#16 0x00007fe614661db3 in QApplication::notify (this=0x7fff756578b0, receiver=0x814fe0, e=0x7fff75657450) at kernel/qapplication.cpp:4412
#17 0x00007fe6194c11c6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib64/libkdeui.so.5
#18 0x00007fe6154f6d0c in QCoreApplication::notifyInternal (this=0x7fff756578b0, receiver=0x814fe0, event=0x7fff75657450) at kernel/qcoreapplication.cpp:915
#19 0x00007fe615527be8 in sendEvent (event=0x7fff75657450, receiver=<optimized out>) at kernel/qcoreapplication.h:231
#20 QTimerInfoList::activateTimers (this=0x6ad768) at kernel/qeventdispatcher_unix.cpp:626
#21 0x00007fe615528ce4 in QEventDispatcherUNIX::processEvents (this=0x607000, flags=...) at kernel/qeventdispatcher_unix.cpp:945
#22 0x00007fe6147014c8 in QEventDispatcherX11::processEvents (this=0x607000, flags=...) at kernel/qeventdispatcher_x11.cpp:152
#23 0x00007fe6154f5842 in QEventLoop::processEvents (this=<optimized out>, flags=...) at kernel/qeventloop.cpp:149
#24 0x00007fe6154f5a97 in QEventLoop::exec (this=0x7fff75657830, flags=...) at kernel/qeventloop.cpp:204
#25 0x00007fe6154fa8b5 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1187
#26 0x00007fe619ceb8e3 in kdemain (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/kde-workspace-4.8.97/kwin/main.cpp:545
#27 0x00007fe61991623d in __libc_start_main () from /lib64/libc.so.6
#28 0x0000000000400681 in _start () at ../sysdeps/x86_64/elf/start.S:113

Possible duplicates by query: bug 171593.

Reported using DrKonqi
Comment 1 Thomas Lübking 2012-07-31 15:44:31 UTC
The backtrace says it crashes in "effects->addRepaintFull();"

-> Does it always look _exactly_ the same (despite memory offsets like "0xf7a780")

What does this mean:
> but when I pushed "intro"
clicking or pressing ctrl+F11 again, etc.. ?
Comment 2 Pedro Martin 2012-08-01 15:14:21 UTC
I mean click enter to back to desktop.

Sorry for bad english.

Brgds
Comment 3 Thomas Lübking 2012-08-01 18:54:54 UTC
No need to excuse for struggles with a foreign language and thanks for the info, but what is far more important is whether all (you said "can be reproduced every time") look exactly the same (for that's actually hardly possible - this crash implies a dangeling effects pointer)
Comment 4 Pedro Martin 2012-08-01 19:30:20 UTC
Yes, all looks exactly the same, if I close segmentation fault message, I see all exactly as before crash, effects work, and you can do Ctrl+F11 again, and  when I push enter  in the keyboard to close cube, it closes and appears again seg-fault message on desktop. 

Brgds
Comment 5 Thomas Lübking 2012-08-01 19:45:33 UTC
I meant whether the texts in the "developer information" tab look all exactly the same (in doubt post one or two)
Comment 6 Pedro Martin 2012-08-02 12:45:03 UTC
Texts in developer information are exactly the same, every time I reproduce crash. 
I created a new user and from this new user there are no crashes, it works perfectly. Maybe some old KDE48 configuration is disturbing.
Comment 7 Pedro Martin 2012-08-02 16:05:03 UTC
Not necessary to create a new user, simply setting cube configuration in systemsettings/Desktop-effects as default, apply, and after this works without issues. You can  configure again cube effects after that with no issues.


Thanks & Brgds
Comment 8 Martin Flöser 2012-08-02 16:23:38 UTC
this seems like we have one option which crashes. You could try to change 
everything again in a way so that it crashes? That is restore your previous 
configuration.

<dev-note>We should add Q_PROPERTIES to all effects and query them in support-
information. /me will work on this for 4.9.1</dev-note>
Comment 9 vinnywright 2012-08-02 18:00:03 UTC
Created attachment 72908 [details]
New crash information added by DrKonqi

kwin (4.9.00) on KDE Platform 4.9.00 using Qt 4.8.1

- What I was doing when the application crashed:alt>F10 for the cube ....spinn cube with the mouse a few times.........hit enter to return to desktop.
crash  Reporter comes up but all looks well.
if top is running you can see it ? stutter wile the cube is up .....same with alt>tab cover flow but no crash yet

-- Backtrace (Reduced):
#6  KWin::CubeEffect::postPaintScreen (this=0x1b21d00) at ../../../kwin/effects/cube/cube.cpp:1172
#7  0x00007f2b98602528 in KWin::EffectsHandlerImpl::postPaintScreen (this=0x1964400) at ../../kwin/effects.cpp:250
#8  0x00007f2b98602528 in KWin::EffectsHandlerImpl::postPaintScreen (this=0x1964400) at ../../kwin/effects.cpp:250
#9  0x00007f2b985e2e70 in KWin::Scene::paintScreen (this=0x1244a00, mask=<optimized out>, region=0x7fff8a6e94e0) at ../../kwin/scene.cpp:150
#10 0x00007f2b985f8fae in KWin::SceneOpenGL::paint (this=0x1244a00, damage=..., toplevels=...) at ../../kwin/scene_opengl_glx.cpp:481
Comment 10 Thomas Lübking 2012-08-02 20:05:18 UTC
Does this crash happen *before* the cube returned to a  "normal" desktop view or *after*?
Comment 11 vinnywright 2012-08-02 20:44:24 UTC
reply to comment #10
after reterning to normal view ......the screen will flicker once and then the crash reporter pops up
VINNY
Comment 12 Pedro Martin 2012-08-03 16:50:35 UTC
Created attachment 72925 [details]
kwin crash handler

After modifyng desktop-effects/cube to default, apply and after configuring again cube effect,
if :
actualize KDE software (yast) or restarting desktop (ctl+del) or going to terminal (ctrl+F1) and frm here init 5, after those events when I hit Ctl +f11 and after hit enter or any key crash handler popup appears.
I try to send the new text from crash.

Brgds
Comment 13 Thomas Lübking 2012-08-03 17:05:30 UTC
can you please attach your ~/.kde/share/config/kwinrc ?
Comment 14 Pedro Martin 2012-08-03 18:02:01 UTC
Created attachment 72929 [details]
kwinrc
Comment 15 Pedro Martin 2012-08-03 18:07:36 UTC
Created attachment 72930 [details]
kwinrc in txt format

Sorry for that , i resend my kwin.rc in plain text.

thanks & best regards
Comment 16 Thomas Lübking 2012-08-03 20:21:22 UTC
Thanks alot.
Bug / crash is absolutely reproducible here. Now let's see why ;-)
Comment 17 Thomas Lübking 2012-08-03 20:34:28 UTC
There's either an offset in my or your sources.
However the crash is due to "desktopNameFrame->free();" and it's because you don't show the desktop name (thus desktopNameFrame is NULL - makes MUCH more sense and can be fixed ;-)

https://git.reviewboard.kde.org/r/105840/
Comment 18 vinnywright 2012-08-03 21:01:29 UTC
conferming comment#17
if I add the desktop name back to the cube settings no more crash :)

VINNY
Comment 19 Pedro Martin 2012-08-04 13:09:00 UTC
Thanks to you both, and to all KDE team, you do a fantastic work.

Best regards

Pedro Martín
Comment 20 Denis M. (Phr33d0m) 2012-08-04 16:19:28 UTC
Created attachment 72957 [details]
New crash information added by DrKonqi

kwin (4.9.00) on KDE Platform 4.9.00 using Qt 4.8.2

- What I was doing when the application crashed:

I've experienced same crash as OP explained. 
Distro: Gentoo amd64

-- Backtrace (Reduced):
#6  0x00007f29aba066c4 in KWin::CubeEffect::postPaintScreen() () from /usr/lib64/kde4/kwin4_effect_builtins.so
#7  0x00007f29b92238a8 in KWin::EffectsHandlerImpl::postPaintScreen() () from /usr/lib64/libkdeinit4_kwin.so
#8  0x00007f29b92238a8 in KWin::EffectsHandlerImpl::postPaintScreen() () from /usr/lib64/libkdeinit4_kwin.so
#9  0x00007f29b9201f4e in KWin::Scene::paintScreen(int*, QRegion*) () from /usr/lib64/libkdeinit4_kwin.so
#10 0x00007f29b9219d36 in KWin::SceneOpenGL::paint(QRegion, QList<KWin::Toplevel*>) () from /usr/lib64/libkdeinit4_kwin.so
Comment 21 Erick Osorio 2012-08-10 09:05:46 UTC
Created attachment 73081 [details]
New crash information added by DrKonqi

kwin (4.9.00 "release 558") on KDE Platform 4.9.00 "release 558" using Qt 4.8.2

- What I was doing when the application crashed:
i have openSUSE 12.1 64 bits with KDE 4.9.

Always happen when desktop cube (ctrl+f11) are activated.

-- Backtrace (Reduced):
#6  KWin::CubeEffect::postPaintScreen (this=0x2582920) at /usr/src/debug/kde-workspace-4.9.0/kwin/effects/cube/cube.cpp:1172
#7  0x00007f2ce8618ed8 in KWin::EffectsHandlerImpl::postPaintScreen (this=0x2195120) at /usr/src/debug/kde-workspace-4.9.0/kwin/effects.cpp:250
#8  0x00007f2ce85f90ee in KWin::Scene::paintScreen (this=0x215c3d0, mask=<optimized out>, region=0x7ffff0501ae0) at /usr/src/debug/kde-workspace-4.9.0/kwin/scene.cpp:150
#9  0x00007f2ce860f9ce in KWin::SceneOpenGL::paint (this=0x215c3d0, damage=..., toplevels=<optimized out>) at /usr/src/debug/kde-workspace-4.9.0/kwin/scene_opengl_glx.cpp:481
#10 0x00007f2ce85f2482 in performCompositing (this=0x20ecb90) at /usr/src/debug/kde-workspace-4.9.0/kwin/composite.cpp:432
Comment 22 Thomas Lübking 2012-08-11 20:34:34 UTC
Git commit eb7a37936ea48eabb74a002001204485dbac0eff by Thomas Lübking.
Committed on 08/08/2012 at 19:48.
Pushed by luebking into branch 'KDE/4.9'.

check desktopNameFrame pointer in cube effect

REVIEW: 105840
FIXED-IN: 4.9.1

M  +2    -1    kwin/effects/cube/cube.cpp

http://commits.kde.org/kde-workspace/eb7a37936ea48eabb74a002001204485dbac0eff