Hopefully fix a crash I encountered in kdevelop; also, the logic looked wrong, take 2...
Hopefully fix a crash I encountered in kdevelop; also, the logic looked wrong, take 2...

svn path=/trunk/KDE/kdelibs/kate/; revision=724724

jfmcarreira/kate,cmacq2/kate,jfmcarreira/kate,sandsmark/kate,sandsmark/kate,hlamer/kate,hlamer/kate,DickJ/kate,sandsmark/kate,DickJ/kate,hlamer/kate,hlamer/kate,hlamer/kate,jfmcarreira/kate,cmacq2/kate,cmacq2/kate,DickJ/kate,DickJ/kate,hlamer/kate,hlamer/kate,sandsmark/kate,hlamer/kate,hlamer/kate,hlamer/kate