[Kita-svn] [2377] avoid a crash on exit

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2009年 7月 7日 (火) 06:02:29 JST


Revision: 2377
          http://sourceforge.jp/projects/kita/svn/view?view=rev&revision=2377
Author:   nogu
Date:     2009-07-07 06:02:29 +0900 (Tue, 07 Jul 2009)

Log Message:
-----------
avoid a crash on exit

Modified Paths:
--------------
    kita/branches/KITA-KDE4/kita/src/libkita/datmanager.cpp

Modified: kita/branches/KITA-KDE4/kita/src/libkita/datmanager.cpp
===================================================================
--- kita/branches/KITA-KDE4/kita/src/libkita/datmanager.cpp	2009-07-06 15:16:44 UTC (rev 2376)
+++ kita/branches/KITA-KDE4/kita/src/libkita/datmanager.cpp	2009-07-06 21:02:29 UTC (rev 2377)
@@ -154,11 +154,8 @@
 /* public */
 void DatManager::deleteAllDatInfo()
 {
-    DatInfoList::Iterator it;
-    for ( it = m_datInfoList.begin(); it != m_datInfoList.end(); ++it ) {
-
-        delete ( *it );
-    }
+    while (!m_datInfoList.isEmpty())
+        delete m_datInfoList.takeFirst();
 }
 
 




Kita-svn メーリングリストの案内
Back to archive index