Fix problem where freed memory is not inserted into the unused ring properly.
authorstefw <stefw@localhost>
Thu, 2 Apr 2009 03:30:07 +0000 (03:30 +0000)
committerstefw <stefw@localhost>
Thu, 2 Apr 2009 03:30:07 +0000 (03:30 +0000)
This caused enless loops. Should fix bug #575247

svn path=/trunk/; revision=1708

egg/egg-secure-memory.c

index 8e26b8d..1d2f48b 100644 (file)
@@ -341,7 +341,7 @@ sec_insert_cell_ring (Cell **ring, Cell *cell)
        /* Insert back into the mix of available memory */
        if (*ring) {
                cell->next = (*ring)->next;
-               cell->prev = (*ring)->prev;
+               cell->prev = *ring;
                cell->next->prev = cell;
                cell->prev->next = cell;
        } else {