X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=blobdiff_plain;f=lib%2Frfxswf.c;h=257d41bd5b9d848c60433ac7b7a32a4c6265fabb;hp=4b64b83d4c3caf006a5413552450d7795bf1e192;hb=08cb34b5daec9b0e7736e19b35ff72a8d9e0348a;hpb=42588d631825c2287f2a1b082f8825423ebb8e3d diff --git a/lib/rfxswf.c b/lib/rfxswf.c index 4b64b83..257d41b 100644 --- a/lib/rfxswf.c +++ b/lib/rfxswf.c @@ -1282,15 +1282,6 @@ int swf_WriteSWF2(writer_t*writer, SWF * swf) // Writes SWF to file, return if(writer) writer_lastpos = writer->pos; - if(swf->fileVersion >= 8) { - if ((swf->firstTag && swf->firstTag->id != ST_FILEATTRIBUTES) && - (!swf->firstTag->next || swf->firstTag->next->id != ST_FILEATTRIBUTES)) - { - U32 flags = 0; // | 128 = usenetwork, | 8 = hasmetadata - swf_SetU32(swf_InsertTagBefore(swf, swf->firstTag,ST_FILEATTRIBUTES),flags); - } - } - // Insert REFLEX Tag #ifdef INSERT_RFX_TAG @@ -1302,6 +1293,14 @@ int swf_WriteSWF2(writer_t*writer, SWF * swf) // Writes SWF to file, return } #endif // INSERT_RFX_TAG + + if(swf->fileVersion >= 8) { + if (swf->firstTag && swf->firstTag->id != ST_FILEATTRIBUTES) + { + U32 flags = 0; // | 128 = usenetwork, | 8 = hasmetadata + swf_SetU32(swf_InsertTagBefore(swf, swf->firstTag,ST_FILEATTRIBUTES),flags); + } + } // Count Frames + File Size