DevHeads.net

Review Request: Fix crash in KDirLister

Review request for kdelibs.

Summary
Attached patch fixes a crash reported by gopalK, one of our Calligra@Windows heros.

Backtrace (only one line);
#0 KDirLister::Private::emitChanges (this=0x13332c70)
at d:\kderoot\git\kdelibs\kio\kio\kdirlister.cpp:2155

The reason is that kDirListerCache->itemsForDir can return NULL. That is handled in all cases in that file except those two lines. The patch fixes it.

p.s. whoever pressed "Ship It" please commit the patch for me and backport cause I didn't had the time to get my kdelibs+kdebase setup updated since the latest moves and renames. Thanks in advance :)

Diffs
kio/kio/kdirlister.cpp d554723

Diff: <a href="http://git.reviewboard.kde.org/r/101560/diff" title="http://git.reviewboard.kde.org/r/101560/diff">http://git.reviewboard.kde.org/r/101560/diff</a>

Testing

Thanks,

Sebastian

Comments

Re: Review Request: Fix crash in KDirLister

By Commit Hook at 06/10/2011 - 03:30

This review has been submitted with commit 1931e645e53458e522cce9c93154489e8c66a875 by Aaron Seigo.

- Commit

On June 9, 2011, 4:29 p.m., Sebastian Sauer wrote:

Re: Review Request: Fix crash in KDirLister

By Commit Hook at 06/10/2011 - 03:30

This review has been submitted with commit 4fad3a34f76d33906e018b42ee909877cea0ef2c by Aaron Seigo.

- Commit

On June 9, 2011, 4:29 p.m., Sebastian Sauer wrote:

Re: Review Request: Fix crash in KDirLister

By Valentin Rusu at 06/09/2011 - 17:20

Ship it!

I checked kdirlister.cpp and itemsForDir truely can return NULL, so the patch seems OK to me

- Valentin

On June 9, 2011, 4:29 p.m., Sebastian Sauer wrote: