X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=blobdiff_plain;f=lib%2Fmodules%2Fswfobject.c;h=a3f1fda0bdce7044b43b7b54e0344d41025c8571;hp=8d69e962db82498d31fb77627b115ddfd70ab8e1;hb=32abc8f4315423d4263ef257db19cb166f097e38;hpb=71a00345eddc8b5ebaacf3ae68afa129a73c4d59 diff --git a/lib/modules/swfobject.c b/lib/modules/swfobject.c index 8d69e96..a3f1fda 100644 --- a/lib/modules/swfobject.c +++ b/lib/modules/swfobject.c @@ -123,10 +123,9 @@ void swf_GetPlaceObject(TAG * tag,SWFPLACEOBJECT* obj) { U8 flags = swf_GetU8(tag); memset(obj,0,sizeof(SWFPLACEOBJECT)); - if(!tag) { - swf_GetMatrix(0,&obj->matrix); - swf_GetCXForm(0,&obj->cxform,1); - } + + swf_GetMatrix(0,&obj->matrix); + swf_GetCXForm(0,&obj->cxform,1); obj->depth = swf_GetU16(tag); //flags&1: move @@ -135,9 +134,12 @@ void swf_GetPlaceObject(TAG * tag,SWFPLACEOBJECT* obj) if(flags&8) swf_GetCXForm(tag, &obj->cxform,1); if(flags&16) obj->ratio = swf_GetU16(tag); if(flags&32) { - int l = strlen(&tag->data[tag->pos]); - int t = 0; - U8*data = malloc(l+1); + int l,t; + U8*data; + swf_ResetReadBits(tag); + l = strlen(&tag->data[tag->pos]); + t = 0; + data = malloc(l+1); obj->name = data; while((data[t++] = swf_GetU8(tag))); }