Opened 15 years ago
Last modified 17 months ago
#4846 assigned bug
thread deadlock in BMenuField
Reported by: | augiedoggie | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | Kits/Interface Kit/BMenu | Version: | R1/alpha1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
While attempting to diagnose a problem in the BeAE program, I came across some odd behavior within BMenuField. The problem only occurs, on average, around 1 out of every 5 tries. Basically you have a BMenuItem attached to a BMenuField, which when selected, destroys the BMenuField object. The BMenuField destructor then gets stuck in wait_for_thread() waiting for the mouse tracking thread to die. I hope I've made that clear :)
I'm attaching some sample code which might explain it better. I assume that this code and the stuff from BeAE worked on BeOS, but, I no longer have it installed to test.
Attachments (1)
Change History (8)
by , 15 years ago
Attachment: | mftest.cpp added |
---|
follow-up: 2 comment:1 by , 15 years ago
comment:2 by , 15 years ago
Replying to augiedoggie:
As a side note. I don't see the attached menu being deleted anywhere in the BMenuField source. Isn't it supposed to own the attached BMenu?
Umm, yeah. Disregard that last comment. I wasn't thinking clearly :) I see the internal menubar and menuitem(s) are added as child views.
comment:4 by , 10 years ago
Replying to jackburton:
Still reproduceable ?
Yes, still locks up the application. Tested on x86_gcc2 - hrev48282
comment:5 by , 8 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:6 by , 4 years ago
I can't apparently reproduce the first problem (but then I'm not sure if the window is hung or not, as it's empty. It does close fine).
I uncommented the call to _CreateView in the attached file. In that situation, it seems that the menu from the newly created menufield opens under the window instead of over it (I can see it after closing the window).
comment:7 by , 17 months ago
Component: | Kits/Interface Kit → Kits/Interface Kit/BMenu |
---|
As a side note. I don't see the attached menu being deleted anywhere in the BMenuField source. Isn't it supposed to own the attached BMenu?