Version: (using KDE Devel) Installed from: Compiled sources Compiler: gcc 3.2 OS: Linux If I want to see the history file from a user which doesn't already have a history file, Kopete crashed. The problem can be found in libkopete/ui/kopetehistorywidget.cpp line 450-456: //Check if thie file exists FILE *f = fopen(QFile::encodeName(*it), "r"); if (f == NULL) { // Oops, no file } If the file doesn't exists, no error message is displayed. line 504: fclose(f); The problem is that fclose(f) is called, even if f==NULL. So fclose(f) crashes.
Subject: kdenonbeta/kopete/libkopete/ui CVS commit by goossens: close file only when it exists heh, this was the same fix as my very first Kopete bugfix so many months ago... brings back memories ;-) you see: history repeats itself (okay, coincidence it's related to a fix in the history dialog :-p ) CCMAIL: 52918-close@bugs.kde.org M +5 -4 kopetehistorywidget.cpp 1.19 --- kdenonbeta/kopete/libkopete/ui/kopetehistorywidget.cpp #1.18:1.19 @@ -500,7 +500,8 @@ int KopeteHistoryWidget::countMessages() } } - } + // Close file only when it exists fclose(f); + } }