MCPcopy Create free account
hub / github.com/dhewm/dhewm3 / MakeTemporaryFile

Method MakeTemporaryFile

neo/framework/FileSystem.cpp:3803–3816  ·  view source on GitHub ↗

=============== idFileSystemLocal::MakeTemporaryFile =============== */

Source from the content-addressed store, hash-verified

3801===============
3802*/
3803idFile * idFileSystemLocal::MakeTemporaryFile( void ) {
3804 FILE *f = tmpfile();
3805 if ( !f ) {
3806 common->Warning( "idFileSystem::MakeTemporaryFile failed: %s", strerror( errno ) );
3807 return NULL;
3808 }
3809 idFile_Permanent *file = new idFile_Permanent();
3810 file->o = f;
3811 file->name = "<tempfile>";
3812 file->fullPath = "<tempfile>";
3813 file->mode = ( 1 << FS_READ ) + ( 1 << FS_WRITE );
3814 file->fileSize = 0;
3815 return file;
3816}
3817
3818/*
3819===============

Callers 1

HandleDownloadsMethod · 0.80

Calls 1

WarningMethod · 0.45

Tested by

no test coverage detected