Walking back closing/opening output file
This commit is contained in:
@@ -819,11 +819,13 @@ int DLLEXPORT EN_closeQ(EN_Project p)
|
|||||||
if (!p->Openflag) return 102;
|
if (!p->Openflag) return 102;
|
||||||
closequal(p);
|
closequal(p);
|
||||||
p->quality.OpenQflag = FALSE;
|
p->quality.OpenQflag = FALSE;
|
||||||
|
/*
|
||||||
if (p->outfile.OutFile != NULL)
|
if (p->outfile.OutFile != NULL)
|
||||||
{
|
{
|
||||||
fclose(p->outfile.OutFile);
|
fclose(p->outfile.OutFile);
|
||||||
p->outfile.OutFile = NULL;
|
p->outfile.OutFile = NULL;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
11
src/report.c
11
src/report.c
@@ -545,11 +545,8 @@ int writeresults(Project *pr)
|
|||||||
if (nnv == 0 && nlv == 0) return errcode;
|
if (nnv == 0 && nlv == 0) return errcode;
|
||||||
|
|
||||||
// Return if no output file
|
// Return if no output file
|
||||||
if (outFile == NULL)
|
// if (outFile == NULL) outFile = fopen(pr->outfile.OutFname, "r+b");
|
||||||
{
|
if (outFile == NULL) return 106;
|
||||||
outFile = fopen(pr->outfile.OutFname, "r+b");
|
|
||||||
if (outFile == NULL) return 106;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Allocate memory for output variables:
|
// Allocate memory for output variables:
|
||||||
// m = larger of # node variables & # link variables
|
// m = larger of # node variables & # link variables
|
||||||
@@ -590,14 +587,14 @@ int writeresults(Project *pr)
|
|||||||
time->Htime += time->Rstep;
|
time->Htime += time->Rstep;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
/*
|
||||||
// Free output file
|
// Free output file
|
||||||
if (outFile != NULL)
|
if (outFile != NULL)
|
||||||
{
|
{
|
||||||
fclose(outFile);
|
fclose(outFile);
|
||||||
outFile = NULL;
|
outFile = NULL;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
// Free allocated memory
|
// Free allocated memory
|
||||||
for (j = 0; j < m; j++) free(x[j]);
|
for (j = 0; j < m; j++) free(x[j]);
|
||||||
free(x);
|
free(x);
|
||||||
|
|||||||
Reference in New Issue
Block a user