1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-06 12:20:30 +00:00

VideoStreamGDNative: close file in cleanup

We should close the file handle when we are done.
This commit is contained in:
Mark Kuo
2020-06-28 10:20:07 +10:00
parent 27378524f2
commit 3b05d2c989

View File

@@ -214,6 +214,11 @@ void VideoStreamPlaybackGDNative::cleanup() {
if (pcm) {
memfree(pcm);
}
if (file) {
file->close();
memdelete(file);
file = nullptr;
}
pcm = nullptr;
time = 0;
num_channels = -1;