From 97adbfa8c76281fb017e7d55bf92b13b608cc975 Mon Sep 17 00:00:00 2001 From: Chris Thrasher Date: Thu, 22 Dec 2022 22:49:28 -0600 Subject: [PATCH] Let compiler generate destructors These destructors call a function that does nothing that the destructors for each member already do so there's no value in calling it. --- src/SFML/Audio/InputSoundFile.cpp | 6 +----- src/SFML/Audio/OutputSoundFile.cpp | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/src/SFML/Audio/InputSoundFile.cpp b/src/SFML/Audio/InputSoundFile.cpp index aa443972c..258eacf55 100644 --- a/src/SFML/Audio/InputSoundFile.cpp +++ b/src/SFML/Audio/InputSoundFile.cpp @@ -66,11 +66,7 @@ InputSoundFile::InputSoundFile() = default; //////////////////////////////////////////////////////////// -InputSoundFile::~InputSoundFile() -{ - // Close the file in case it was open - close(); -} +InputSoundFile::~InputSoundFile() = default; //////////////////////////////////////////////////////////// diff --git a/src/SFML/Audio/OutputSoundFile.cpp b/src/SFML/Audio/OutputSoundFile.cpp index 2f1995b22..4222ca80c 100644 --- a/src/SFML/Audio/OutputSoundFile.cpp +++ b/src/SFML/Audio/OutputSoundFile.cpp @@ -37,11 +37,7 @@ OutputSoundFile::OutputSoundFile() = default; //////////////////////////////////////////////////////////// -OutputSoundFile::~OutputSoundFile() -{ - // Close the file in case it was open - close(); -} +OutputSoundFile::~OutputSoundFile() = default; ////////////////////////////////////////////////////////////