Version: 3.0 (using KDE KDE 3.1.93) Installed from: Gentoo Packages Compiler: gcc 3.3.2 OS: Linux I have KNotes started with a tray icon. When I first started it an initial note was created. I didn't need it so I deleted it. Each time I login I see the same note I deleted and I delete it again. It comes back when I login again. The date on the note is the same as the first initial note when I started KNotes days ago. Expected behavior: 1. If I delete a note it should be deleted. 2. If I have no notes on my desktop when I logout, I don't want any when I login again. This all may be related to the fact that I have no notes in KNotes.
I am getting similar behavior, with Mandrake packages from KDE 3.1.94. I didn't have an "initial note" as the reporter describes, but one day I decided to create two notes on which I typed some text. A few days later I didn't want them anymore, so I deleted them. They disappeared from my desktop, as expected, but they reappeared the next time I logged in, and now I have to delete them every time I log in.
This appears to have been fixed with 3.2 beta 2.
Confirmed, an upgrade to the latest CVS cured it.
This bug appears to be back with 3.2 rc 1.
CVS commit by brade: Laurent, your commit did not only introduce a memory leak but also caused #68127 -- notes were not really deleted if deleting was the last action before quitting KNotes since the destructors were not called. I will add some more safety checks though. CCMAIL: 68127-done@bugs.kde.org M +12 -3 ChangeLog 1.59 M +9 -4 main.cpp 1.23 M +1 -0 main.h 1.3 --- kdepim/knotes/main.h #1.2:1.3 @@ -32,4 +32,5 @@ class Application : public KUniqueApplic public: Application(); + ~Application(); virtual int newInstance(); --- kdepim/knotes/main.cpp #1.22:1.23 @@ -32,8 +32,14 @@ using namespace std; -Application::Application() : KUniqueApplication(), mMainWindow( 0 ) +Application::Application() + : KUniqueApplication(), mMainWindow( 0 ) { } +Application::~Application() +{ + delete mMainWindow; +} + int Application::newInstance() { @@ -44,7 +50,6 @@ int Application::newInstance() } else - { - mMainWindow->newNote( ); - } + mMainWindow->newNote(); + return KUniqueApplication::newInstance(); } --- kdepim/knotes/ChangeLog #1.58:1.59 @@ -2,9 +2,18 @@ ==================== +2004/03/09 Michael Brade <brade@kde.org> + + * fixed #68127: notes are not really deleted if deleting is the last + action before quitting KNotes + +2004/03/08 Michael Brade <brade@kde.org> + + * new version: 3.1 + 2004/03/06 Michael Brade <brade@kde.org> - * fixed 72818: add a tooltip - * fixed 74469: RMB menu locks whole desktop if opened on a modified note - * fixed 75507, 76126: handle (load) tabs correctly, fix in libical + * fixed #72818: add a tooltip + * fixed #74469: RMB menu locks whole desktop if opened on a modified note + * fixed #75507, #76126: handle (load) tabs correctly, fix in libical * removed hack for the fix for #57367
I have this problem in KNotes 3.3, using KDE 3.3.1-4.1.2.kde, gcc-3.3.3-7 on FC2. My config is: /.kde/share/apps/knotes/notes.ics and /.kde/share/apps/knotes/notes directory Few records from notes.ics pop up on the screen every time I start Knotes. The records I deleted before using Knotes rather then using Kontact Notes. Vladimir