loadsave.c: function Remove_file()
This commit is contained in:
parent
3ed5dc5786
commit
3a0e187d73
@ -1769,3 +1769,13 @@ FILE * Open_file_read(T_IO_Context *context)
|
|||||||
|
|
||||||
return fopen(filename, "rb");
|
return fopen(filename, "rb");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// For use by Save_XXX() functions
|
||||||
|
void Remove_file(T_IO_Context *context)
|
||||||
|
{
|
||||||
|
char filename[MAX_PATH_CHARACTERS]; // filename with full path
|
||||||
|
|
||||||
|
Get_full_filename(filename, context->File_name, context->File_directory);
|
||||||
|
|
||||||
|
remove(filename);
|
||||||
|
}
|
||||||
|
|||||||
@ -267,4 +267,6 @@ FILE * Open_file_write(T_IO_Context *context);
|
|||||||
/// For use by Load_XXX() and Test_XXX() functions
|
/// For use by Load_XXX() and Test_XXX() functions
|
||||||
FILE * Open_file_read(T_IO_Context *context);
|
FILE * Open_file_read(T_IO_Context *context);
|
||||||
|
|
||||||
|
/// For use by Save_XXX() functions
|
||||||
|
void Remove_file(T_IO_Context *context);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user