removed framerate>0 restriction in order to make Flash Communication Server
[swftools.git] / src / png2swf.c
index 91cfb32..2146ef7 100644 (file)
@@ -746,9 +746,10 @@ int CheckInputFile(char *fname, char **realname)
            sprintf(s, "%s.PNG", fname);
            if ((fi = fopen(s, "rb")) == NULL) {
                sprintf(s, "%s.Png", fname);
-               if ((fi = fopen(s, "rb")) == NULL)
+               if ((fi = fopen(s, "rb")) == NULL) {
                    fprintf(stderr, "Couldn't open %s!\n", fname);
                    return -1;
+               }
            }
        }
     }
@@ -778,7 +779,9 @@ int args_callback_option(char *arg, char *val)
        case 'r':
            if (val)
                global.framerate = atof(val);
-           if ((global.framerate < 1.0/256) ||(global.framerate >= 256.0)) {
+           /* removed framerate>0 restriction in order to make
+              Flash Communication Server compatible SWFs */
+           if ((global.framerate < 0) ||(global.framerate >= 256.0)) {
                if (VERBOSE(1))
                    fprintf(stderr,
                            "Error: You must specify a valid framerate between 1/256 and 255.\n");