[haiku-bugs] Re: [Haiku] #12286: Menus seem to be leaking ports

  • From: "bonefish" <trac@xxxxxxxxxxxx>
  • Date: Thu, 06 Aug 2015 15:10:09 -0000

#12286: Menus seem to be leaking ports
----------------------------------+----------------------------
Reporter: ttcoder | Owner: axeld
Type: bug | Status: new
Priority: high | Milestone: R1/beta1
Component: Kits/Interface Kit | Version: R1/Development
Resolution: | Keywords:
Blocked By: | Blocking:
Has a Patch: 0 | Platform: All
----------------------------------+----------------------------

Comment (by bonefish):

Replying to [comment:15 ttcoder]:

The [http://cgit.haiku-
os.org/haiku/commit/?id=285b7163ad41e00841d0dc28b48fe10902a350bc change]
includes a creation of a MouseDownThread indeed. But maybe that class can
be fixed.

Is it correct to say the class would be fully fixed by removing the
kill_thread() call in dtor, the ASSERT() in Track(), and the TRESPASS() in
the dtor ?

Removing the kill_thread would let the dtor complete cleanly, return
control to Track(), and exit the thread ?

It depends on the other uses. If it is expected that any other thread can
destroy the object then it wouldn't work. Without ref-counting that would
be unsafe anyway, though.

PS - maybe it's time to track that issue in another ticket, as it's
unrelated to the port leak (unless I missed something :-)

I also see no immediate connection to the leaked ports.

--
Ticket URL: <https://dev.haiku-os.org/ticket/12286#comment:18>
Haiku <https://dev.haiku-os.org>
Haiku - the operating system.

Other related posts: