> On Jan. 29, 2011, 9:28 p.m., Raphael Kubo da Costa wrote: > > So you're saying is that on each login a new YahooAccount (which creates a > > Client) is created? Do you know what part of the code creates this object? > > My doubt is this: if the code which does this does not immediately delete > > the previous YahooAccount, then Client's destructor will not be immediately > > called and the "leak" will continue; if, OTOH, the code does delete the > > previous YahooAccount, then Client's destructor will be called, and so will > > d->root's, hence the "leak" should not happen. > > > > I also did not understand why some objects are being deleted with 'delete > > foo;' and others with 'foo->deleteLater()'. > > > > One last thing: do you know if the task objects created in methods such as > > receiveFile() are also being "leaked" this way?
No, I'm not saying that. YahooAccount object - deleted probably only when quiting kopete. Same for the Client object. but Client::close() is called at various times - when going offline or networking errors. So, the pairs initTasks and close (and deleteTask) are called at various time during lifetime of kopete - usually when switching between offline/other status. So they both must know correctly about subtasks being created or not - that's the missing tasksInitia... = true for - probably original author forgot about it? Why using both delete and deleteLater - don't have a very good clue. tasks created like in receiveFile - they're being run w/ go(true) - which means autoDelete themselves. > On Jan. 29, 2011, 9:28 p.m., Raphael Kubo da Costa wrote: > > trunk/KDE/kdenetwork/kopete/protocols/yahoo/libkyahoo/client.cpp, line 157 > > <http://svn.reviewboard.kde.org/r/6422/diff/1/?file=44611#file44611line157> > > > > No need for this check -- delete on a NULL-pointer does not do anything. shame on me. you can remove that. - Cristi ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: http://svn.reviewboard.kde.org/r/6422/#review9761 ----------------------------------------------------------- On Jan. 29, 2011, 3:46 p.m., Cristi P wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > http://svn.reviewboard.kde.org/r/6422/ > ----------------------------------------------------------- > > (Updated Jan. 29, 2011, 3:46 p.m.) > > > Review request for Kopete. > > > Summary > ------- > > while looking for cause of duplicate incoming messages problems, I found some > missing code that made program recreate some objects. > > > Diffs > ----- > > trunk/KDE/kdenetwork/kopete/protocols/yahoo/libkyahoo/client.cpp 1217129 > > Diff: http://svn.reviewboard.kde.org/r/6422/diff > > > Testing > ------- > > sending messages, sending files still work. > put some dump in constructor and destructor of a webcamtask to confirm it was > not deleting the task but just creating new ones - when reconnecting. > > > Thanks, > > Cristi > >
_______________________________________________ kopete-devel mailing list kopete-devel@kde.org https://mail.kde.org/mailman/listinfo/kopete-devel