MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / dFileDelete

Function dFileDelete

Engine/source/platformWin32/winFileio.cpp:50–67  ·  view source on GitHub ↗

-----------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

48
49//-----------------------------------------------------------------------------
50bool dFileDelete(const char * name)
51{
52 AssertFatal( name != NULL, "dFileDelete - NULL file name" );
53
54 TempAlloc< TCHAR > buf( dStrlen( name ) + 1 );
55
56#ifdef UNICODE
57 convertUTF8toUTF16N( name, buf, buf.size );
58#else
59 dStrcpy( buf, name, buf.size );
60#endif
61
62 backslash( buf );
63 if( Platform::isFile( name ) )
64 return DeleteFile( buf );
65 else
66 return RemoveDirectory( buf );
67}
68
69bool Platform::fileDelete(const char * name)
70{

Callers 5

mergeModulesMethod · 0.50
deleteAssetMethod · 0.50
processCacheMethod · 0.50
TESTFunction · 0.50

Calls 4

convertUTF8toUTF16NFunction · 0.85
dStrcpyFunction · 0.85
backslashFunction · 0.85
dStrlenFunction · 0.50

Tested by 1

TESTFunction · 0.40