fixed a bug occuring when shapes are entirely outside of the viewport
[swftools.git] / lib / modules / swfrender.c
index fd9cb1a..e085937 100644 (file)
@@ -832,6 +832,8 @@ void swf_Process(RENDERBUF*dest, U32 clipdepth)
                 endx = i->width2;
             if(startx < 0)
                 startx = 0;
+            if(endx < 0)
+                endx = 0;
 
            if(clipdepth) {
                /* for clipping, the inverse is filled */
@@ -1014,6 +1016,7 @@ void swf_RenderSWF(RENDERBUF*buf, SWF*swf)
             swf_GetPlaceObject(tag, &p);
             /* TODO: add move and deletion */
             placements[numplacements++] = p;
+           swf_PlaceObjectFree(&p); //dirty! but it only removes items we don't need
         }
         tag = tag->next;
     }
@@ -1053,6 +1056,7 @@ void swf_RenderSWF(RENDERBUF*buf, SWF*swf)
             }
         }
     }
+    free(placements);
     free(idtable);
     free(depthtable);
 }