Opened 12 years ago

Closed 11 years ago

#1626 closed bug (fixed)

GLTeapot doesn't quit

Reported by: vzsolt Owned by: axeld
Priority: normal Milestone: R1
Component: Kits/OpenGL Kit Version: R1/pre-alpha1
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All

Description

I was trying out the demos in hrev22928, in VMWare, and found that GLTeapot doesn't quit, neither when closing it's window, nor when using the keyboard shortcut. It hangs in Deskbar, with no windows, and can't be closed from there either.

On shutdown, the Shutdown Status dialog asks this question: "The application "GLTeapot" might be blocked on a modal panel." Kill/Cancel

In terminal, ps shows two entries related to GLTeapot, with semaphores GLTeapot, and thread_99_retcode_sem. (I'm not sure how to interpret this...)

And I can't start it again.

Attachments (1)

bt.PNG (44.1 KB) - added by jackburton 11 years ago.

Download all attachments as: .zip

Change History (7)

comment:1 Changed 12 years ago by phoudoin

Owner: changed from axeld to phoudoin

comment:2 Changed 11 years ago by jackburton

This doesn't happen every time, though.

comment:3 Changed 11 years ago by jackburton

I tried to drop the window thread into the debugger after it's stuck (exiting via ALT-W). Here's the backtrace.

Changed 11 years ago by jackburton

Attachment: bt.PNG added

comment:4 Changed 11 years ago by jackburton

So, what's happening is that the BWindow thread tries to acquire the window's lock, but it's already acquired by the BApplication (inside WindowQuitLoop()), so there's a deadlock. Maybe we have to review our quitting path again ?

comment:5 Changed 11 years ago by axeld

Component: - ApplicationsKits/OpenGL Kit
Owner: changed from phoudoin to axeld
Status: newassigned

comment:6 Changed 11 years ago by axeld

Resolution: fixed
Status: assignedclosed

What actually happened was that the "simon" thread would not always release the window lock it locked when it called the ObjectView's DrawFrame() method. It wouldn't release it because the GLRenderer is already removed after DetachFromWindow() has been called.

Fixed in hrev23691.

Note: See TracTickets for help on using tickets.