2007-08-24 21:49:07 +02:00
|
|
|
#include <stdio.h>
|
|
|
|
#include <string.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
2016-05-19 14:15:22 +02:00
|
|
|
int fclose(FILE* file)
|
2006-09-07 16:14:53 +02:00
|
|
|
{
|
2016-05-19 14:15:22 +02:00
|
|
|
if(!file)
|
|
|
|
{
|
|
|
|
errno = E_INVALIDPTR;
|
|
|
|
return EOF;
|
|
|
|
}
|
|
|
|
|
|
|
|
if(file->buffer)
|
|
|
|
free(file->buffer);
|
2006-09-07 16:14:53 +02:00
|
|
|
free(file);
|
2016-05-19 14:15:22 +02:00
|
|
|
|
|
|
|
return 0;
|
|
|
|
}
|