Fixed abc eeror handling
authorClifford Wolf <clifford@clifford.at>
Mon, 18 Mar 2013 06:31:59 +0000 (07:31 +0100)
committerClifford Wolf <clifford@clifford.at>
Mon, 18 Mar 2013 06:31:59 +0000 (07:31 +0100)
passes/abc/abc.cc

index b7680f06e781a4c1f97ea88eb4e191216763560d..ccf0fccb35099fbb5c14c4817655a2efe0c18846 100644 (file)
@@ -356,7 +356,7 @@ static void abc_module(RTLIL::Design *design, RTLIL::Module *current_module, std
 
        if (asprintf(&p, "%s/input.v", tempdir_name) < 0) abort();
        FILE *f = fopen(p, "wt");
-       if (f == NULL);
+       if (f == NULL)
                log_error("Opening %s for writing failed: %s\n", p, strerror(errno));
        free(p);
 
@@ -420,7 +420,7 @@ static void abc_module(RTLIL::Design *design, RTLIL::Module *current_module, std
 
                if (asprintf(&p, "%s/stdcells.genlib", tempdir_name) < 0) abort();
                f = fopen(p, "wt");
-               if (f == NULL);
+               if (f == NULL)
                        log_error("Opening %s for writing failed: %s\n", p, strerror(errno));
                fprintf(f, "GATE ZERO 1 Y=CONST0;\n");
                fprintf(f, "GATE ONE  1 Y=CONST1;\n");