============ FS_WriteFile Filename are reletive to the quake search path ============ */
| 1824 | ============ |
| 1825 | */ |
| 1826 | void FS_WriteFile( const char *qpath, const void *buffer, int size ) { |
| 1827 | fileHandle_t f; |
| 1828 | |
| 1829 | FS_AssertInitialised(); |
| 1830 | |
| 1831 | if ( !qpath || !buffer ) { |
| 1832 | Com_Error( ERR_FATAL, "FS_WriteFile: NULL parameter" ); |
| 1833 | } |
| 1834 | |
| 1835 | f = FS_FOpenFileWrite( qpath ); |
| 1836 | if ( !f ) { |
| 1837 | Com_Printf( "Failed to open %s\n", qpath ); |
| 1838 | return; |
| 1839 | } |
| 1840 | |
| 1841 | FS_Write( buffer, size, f ); |
| 1842 | |
| 1843 | FS_FCloseFile( f ); |
| 1844 | } |
| 1845 | |
| 1846 | /* |
| 1847 | ========================================================================== |
nothing calls this directly
no test coverage detected