From kde-core-devel Mon Nov 19 22:06:09 2007 From: David Faure Date: Mon, 19 Nov 2007 22:06:09 +0000 To: kde-core-devel Subject: Re: KJob deleting itself too early? Message-Id: <200711192306.09571.faure () kde ! org> X-MARC-Message: https://marc.info/?l=kde-core-devel&m=119551002115979 On Sunday 18 November 2007, Andreas Pakulat wrote: > Hi, > > I'd like to know why KJob deletes itself when he's done doing its work? > Shouldn't this be done by whoever creates the KJob? No, many jobs are fire-and-forget, and when they're not, people would forget to delete them. The job is done, it's done, it deletes itself. KDE3's KIO::Job has always worked like that. > I don't think its a good idea to delete the job behind the back of the > user, in particular when you don't know how a KJob instance (or subclass > thereof) is used. Doesn't matter how it's used: after the job emits finished, it's finished :) -- David Faure, faure@kde.org, sponsored by Trolltech to work on KDE, Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).