forked from speed-dreams/speed-dreams-code
close files when done writing
git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@7140 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: 4ce29bc2abe7f779b798f6611f4fd73a39f24a4d Former-commit-id: 93b0e4f658816e98270bcbac2875c81ca63710c1
This commit is contained in:
parent
bdd4d56678
commit
95a3a8fbcf
1 changed files with 7 additions and 0 deletions
|
@ -3017,6 +3017,7 @@ void computeSaveAC3D(char * OutputFilename, ob_t * object)
|
||||||
/* do the job */
|
/* do the job */
|
||||||
printf("\nend\n");
|
printf("\nend\n");
|
||||||
|
|
||||||
|
fclose(ofile);
|
||||||
}
|
}
|
||||||
|
|
||||||
void computeSaveOBJ(char * OutputFilename, ob_t * object)
|
void computeSaveOBJ(char * OutputFilename, ob_t * object)
|
||||||
|
@ -3313,6 +3314,8 @@ void computeSaveOBJ(char * OutputFilename, ob_t * object)
|
||||||
tmpob = tmpob->next;
|
tmpob = tmpob->next;
|
||||||
}
|
}
|
||||||
fprintf(ofile, "end \n");
|
fprintf(ofile, "end \n");
|
||||||
|
|
||||||
|
fclose(ofile);
|
||||||
}
|
}
|
||||||
|
|
||||||
void stripifyOb(ob_t * object, int writeit)
|
void stripifyOb(ob_t * object, int writeit)
|
||||||
|
@ -3413,18 +3416,21 @@ void stripifyOb(ob_t * object, int writeit)
|
||||||
if ((mem = malloc(sizeof(unsigned int) * NumStripPoints)) == 0)
|
if ((mem = malloc(sizeof(unsigned int) * NumStripPoints)) == 0)
|
||||||
{
|
{
|
||||||
printf("Problem mallocing while stripifying\n");
|
printf("Problem mallocing while stripifying\n");
|
||||||
|
fclose(stripein);
|
||||||
exit(-1);
|
exit(-1);
|
||||||
}
|
}
|
||||||
StripPoint = (unsigned int *) mem;
|
StripPoint = (unsigned int *) mem;
|
||||||
if ((mem = malloc(sizeof(unsigned int) * NumStrips)) == 0)
|
if ((mem = malloc(sizeof(unsigned int) * NumStrips)) == 0)
|
||||||
{
|
{
|
||||||
printf("Problem mallocing while stripifying\n");
|
printf("Problem mallocing while stripifying\n");
|
||||||
|
fclose(stripein);
|
||||||
exit(-1);
|
exit(-1);
|
||||||
}
|
}
|
||||||
StripStart = (unsigned int *) mem;
|
StripStart = (unsigned int *) mem;
|
||||||
if ((mem = malloc(sizeof(unsigned int) * NumStrips)) == 0)
|
if ((mem = malloc(sizeof(unsigned int) * NumStrips)) == 0)
|
||||||
{
|
{
|
||||||
printf("Problem mallocing while stripifying\n");
|
printf("Problem mallocing while stripifying\n");
|
||||||
|
fclose(stripein);
|
||||||
exit(-1);
|
exit(-1);
|
||||||
}
|
}
|
||||||
StripLength = (unsigned int *) mem;
|
StripLength = (unsigned int *) mem;
|
||||||
|
@ -4727,6 +4733,7 @@ void computeSaveAC3DStrip(char * OutputFilename, ob_t * object)
|
||||||
/* do the job */
|
/* do the job */
|
||||||
printf("\nend\n");
|
printf("\nend\n");
|
||||||
|
|
||||||
|
fclose(ofile);
|
||||||
}
|
}
|
||||||
|
|
||||||
ob_t * mergeObject(ob_t *ob1, ob_t * ob2, char * nameS)
|
ob_t * mergeObject(ob_t *ob1, ob_t * ob2, char * nameS)
|
||||||
|
|
Loading…
Reference in a new issue