reworked compression handling logic
[swftools.git] / lib / devices / swf.c
index 2765d68..05567ae 100644 (file)
@@ -26,6 +26,9 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>
 #endif
+#ifdef HAVE_IO_H
+#include <io.h>
+#endif
 #ifdef HAVE_ASSERT_H
 #include <assert.h>
 #else
@@ -1275,13 +1278,8 @@ int swfresult_save(gfxresult_t*gfx, const char*filename)
        return -1;
     }
     
-    if(swf->compressed) {
-       if FAILED(swf_WriteSWC(fi,swf)) 
-           msg("<error> WriteSWC() failed.\n");
-    } else {
-       if FAILED(swf_WriteSWF(fi,swf)) 
-           msg("<error> WriteSWF() failed.\n");
-    }
+    if FAILED(swf_WriteSWF(fi,swf)) 
+        msg("<error> WriteSWF() failed.\n");
 
     if(filename)
      close(fi);