diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-03-01 18:03:41 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-03-01 18:03:41 +0300 |
commit | c56844f6f10fc12410b6554fbefe361bfd8630f6 (patch) | |
tree | 811c184c9169d253eaaaf549823f5e90a36f03ee /src | |
parent | 7df01a8695e46e7e8cce603782f0e16caf54169b (diff) | |
download | mv-c56844f6f10fc12410b6554fbefe361bfd8630f6.tar.gz mv-c56844f6f10fc12410b6554fbefe361bfd8630f6.tar.bz2 mv-c56844f6f10fc12410b6554fbefe361bfd8630f6.tar.xz mv-c56844f6f10fc12410b6554fbefe361bfd8630f6.zip |
Fix closing physfs files.
Diffstat (limited to 'src')
-rw-r--r-- | src/fs/physfs/virtfileprivate.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/fs/physfs/virtfileprivate.cpp b/src/fs/physfs/virtfileprivate.cpp index 9df6e9578..4fcc0968e 100644 --- a/src/fs/physfs/virtfileprivate.cpp +++ b/src/fs/physfs/virtfileprivate.cpp @@ -26,3 +26,9 @@ VirtFilePrivate::VirtFilePrivate(PHYSFS_file *restrict const file) : mFile(file) { } + +VirtFilePrivate::~VirtFilePrivate() +{ + if (mFile != nullptr) + PHYSFS_close(mFile); +} |