/* freopen( const char *, const char *, FILE * )
This file is part of the Public Domain C Library (PDCLib).
/* freopen( const char *, const char *, FILE * )
This file is part of the Public Domain C Library (PDCLib).
if ( ( filename == NULL ) && ( stream->filename == NULL ) )
{
/* TODO: Special handling for mode changes on std-streams */
if ( ( filename == NULL ) && ( stream->filename == NULL ) )
{
/* TODO: Special handling for mode changes on std-streams */
It does not matter with the current implementation of clearerr(),
but it might start to matter if someone replaced that implementation.
*/
It does not matter with the current implementation of clearerr(),
but it might start to matter if someone replaced that implementation.
*/
return NULL;
}
strcpy( stream->filename, filename );
}
if ( ( mode == NULL ) || ( filename[0] == '\0' ) )
{
return NULL;
}
strcpy( stream->filename, filename );
}
if ( ( mode == NULL ) || ( filename[0] == '\0' ) )
{
if ( ! _PDCLIB_open( &stream->handle, &stream->ops, filename,
stream->status ) )
{
if ( ! _PDCLIB_open( &stream->handle, &stream->ops, filename,
stream->status ) )
{