| 3295 | } |
| 3296 | |
| 3297 | static int fclose(FILE *stream) |
| 3298 | { |
| 3299 | int result1 = fflush(stream); |
| 3300 | int result2 = close(stream->fd); |
| 3301 | stdio_stream_free(stream); |
| 3302 | return (result1 == 0? result2: result1); |
| 3303 | } |
| 3304 | |
| 3305 | static FILE *freopen(const char *path, const char *mode, FILE *stream) |
| 3306 | { |