aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: memleak in OnRightClick  (Read 2915 times)

dolphinX

  • Newbie
  • Karma: 0
  • Offline Offline
  • Posts: 1
memleak in OnRightClick
« on: October 20, 2009, 03:54:33 AM »

Hi

in void CFriendListCtrl::OnRightClick(wxMouseEvent& event) @ FriendListCtrl.cpp
forgot to "delete menu;"

and void CServerListCtrl::OnItemRightClicked(wxListEvent& event) @ ServerListCtrl.cpp
forgot to "delete serverMenu;"
Logged

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: memleak in OnRightClick
« Reply #1 on: October 20, 2009, 07:16:02 AM »

No, I don't think so. Can't delete a popup menu unless it's dismissed, and the popup menu is deleted automatically.


Haven't checked the source tho.
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: memleak in OnRightClick
« Reply #2 on: October 20, 2009, 09:29:27 PM »

You're right, dolphinX. wx docu states that the menu isn't deleted by the function, and it's deleted everywhere else in our code. Fixed in 9841, thank you!
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: memleak in OnRightClick
« Reply #3 on: October 20, 2009, 10:09:59 PM »

And I was wrong, product of not looking before talking!
Logged