Review Request 108770: Fix double-free in ~KCompositeJobPrivate

Kevin Funk krf at gmx.de
Mon Feb 4 09:29:22 GMT 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/108770/
-----------------------------------------------------------

Review request for kdelibs.


Description
-------

Fix double-free in ~KCompositeJobPrivate

In case a subjob of KCompositeJob has been deleted, this KCompositeJob
instance will crash as soon as it is being destructed, trying to delete
this subjob again.

This fixes a bug in KDevelop.

Backtrace:
1 0x00007ffff7a3f28e in qDeleteAll<QList<KJob*>::const_iterator>
(end=..., begin=...) at /usr/include/qt4/QtCore/qalgorithms.h:322
2 qDeleteAll<QList<KJob*> > (c=QList<KJob *> = {...}) at
/usr/include/qt4/QtCore/qalgorithms.h:330 #3
KCompositeJobPrivate::~KCompositeJobPrivate (this=0x8849850,
__in_chrg=<optimized out>) at ../../kdecore/jobs/kcompositejob.cpp:29
4 0x00007ffff7a3f2c9 in KCompositeJobPrivate::~KCompositeJobPrivate
(this=0x8849850, __in_chrg=<optimized out>) at
../../kdecore/jobs/kcompositejob.cpp:30
5 0x00007ffff7a3fd70 in KJob::~KJob (this=0x880b030, __in_chrg=<optimized out>) at
../../kdecore/jobs/kjob.cpp:73
6 0x00007ffff1a8e5d9 in KDevelop::BuilderJob::~BuilderJob (this=0x880b030, __in_chrg=<optimized
out>) at /home/krf/devel/src/kdevplatform/project/builderjob.cpp:158

BUG: 230692
FIXED-IN: 4.11


Diffs
-----

  kdecore/jobs/kcompositejob.h 6ca8eed3ebf8c6f0f5c68d8843bd09a3ea928bbd 
  kdecore/jobs/kcompositejob.cpp 5ddabd71e5bbb5f0a555a201223a52950b85e786 
  kdecore/jobs/kcompositejob_p.h bef06e9bff532b45a8d66380a65117737275be9e 

Diff: http://git.reviewboard.kde.org/r/108770/diff/


Testing
-------


Thanks,

Kevin Funk

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20130204/47018540/attachment.htm>


More information about the kde-core-devel mailing list