r3881 - trunk/birnet



Author: timj
Date: 2006-09-11 19:42:06 -0400 (Mon, 11 Sep 2006)
New Revision: 3881

Modified:
   trunk/birnet/ChangeLog
   trunk/birnet/birnetutilsxx.cc
Log:
Tue Sep 12 01:41:18 2006  Tim Janik  <timj gtk org>                                                                                                           
                                                                                                                                                              
        * birnetutilsxx.cc (rip_data): fix missing updates of 'last' pointer                                                                                  
        wich caused data loss.                                                                                                                                
                                                                                                                                                              



Modified: trunk/birnet/ChangeLog
===================================================================
--- trunk/birnet/ChangeLog	2006-09-10 20:48:03 UTC (rev 3880)
+++ trunk/birnet/ChangeLog	2006-09-11 23:42:06 UTC (rev 3881)
@@ -1,3 +1,8 @@
+Tue Sep 12 01:41:18 2006  Tim Janik  <timj gtk org>
+
+	* birnetutilsxx.cc (rip_data): fix missing updates of 'last' pointer
+	wich caused data loss.
+
 Thu Aug 23 21:21:00 2006  Tim Janik  <timj gtk org>
 
 	* birnetcore.h, birnetutilsxx.hh: always use global uint definition

Modified: trunk/birnet/birnetutilsxx.cc
===================================================================
--- trunk/birnet/birnetutilsxx.cc	2006-09-10 20:48:03 UTC (rev 3880)
+++ trunk/birnet/birnetutilsxx.cc	2006-09-11 23:42:06 UTC (rev 3881)
@@ -392,7 +392,7 @@
 DataList::rip_data (DataKey<void> *key)
 {
   NodeBase *last = NULL, *it;
-  for (it = nodes; it; it = it->next)
+  for (it = nodes; it; last = it, it = last->next)
     if (it->key == key)
       {
         /* unlink existing node */




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]