]> git.ipfire.org Git - thirdparty/plymouth.git/commitdiff
[region] Remove element only after processing
authorCharlie Brej <cbrej@cs.man.ac.uk>
Sun, 22 Nov 2009 22:53:12 +0000 (22:53 +0000)
committerCharlie Brej <cbrej@cs.man.ac.uk>
Sun, 22 Nov 2009 22:53:12 +0000 (22:53 +0000)
Now that we cannot rely on the next_node element. We must finish processing the
entry before removing it. Easiest way is to recurse and remove after return.

src/libply/ply-region.c

index b5e48fa5b1c65de9cefb34ee6099d44421f0b709..74b5c864e11078a784e8f4852e92d49d12f1d605 100644 (file)
@@ -283,9 +283,10 @@ merge_rectangle_with_sub_list (ply_region_t    *region,
            * NNNNNNN
            */
           case PLY_RECTANGLE_OVERLAP_ALL_EDGES:
+            merge_rectangle_with_sub_list (region, new_area, next_node);
             free (old_area);
             ply_list_remove_node (region->rectangle_list, node);
-          break;
+          return;
 
           /*  NNN  We need to split the new rectangle into
            * ONNNO two rectangles: the top and bottom row of Ns