================ idDemoFile::Close ================ */
| 184 | ================ |
| 185 | */ |
| 186 | void idDemoFile::Close() { |
| 187 | if ( writing && compressor ) { |
| 188 | compressor->FinishCompress(); |
| 189 | } |
| 190 | |
| 191 | if ( f ) { |
| 192 | fileSystem->CloseFile( f ); |
| 193 | f = NULL; |
| 194 | } |
| 195 | if ( fLog ) { |
| 196 | fileSystem->CloseFile( fLog ); |
| 197 | fLog = NULL; |
| 198 | } |
| 199 | if ( fileImage ) { |
| 200 | Mem_Free( fileImage ); |
| 201 | fileImage = NULL; |
| 202 | } |
| 203 | if ( compressor ) { |
| 204 | delete compressor; |
| 205 | compressor = NULL; |
| 206 | } |
| 207 | |
| 208 | demoStrings.DeleteContents( true ); |
| 209 | } |
| 210 | |
| 211 | /* |
| 212 | ================ |
nothing calls this directly
no test coverage detected