From 832fd0e1b6aff8579c015c176037a899f7519acf Mon Sep 17 00:00:00 2001 From: Kyzentun Keeslala Date: Thu, 4 Aug 2016 16:57:31 -0600 Subject: [PATCH] Use case insensitive lookup when removing invalid sound drivers, the same lookup used when creating the sound driver. Change ffmpeg fetching to fetch from stepmania's mirror because ffmpeg.org moved theirs. --- CMake/SetupFfmpeg.cmake | 2 +- src/arch/Sound/RageSoundDriver.cpp | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/CMake/SetupFfmpeg.cmake b/CMake/SetupFfmpeg.cmake index 02fa749dfe..c8e2ceb25a 100644 --- a/CMake/SetupFfmpeg.cmake +++ b/CMake/SetupFfmpeg.cmake @@ -69,7 +69,7 @@ if (IS_DIRECTORY "${SM_FFMPEG_SRC_DIR}") else() # --shlibdir=$our_installdir/stepmania-$VERSION externalproject_add("ffmpeg" - DOWNLOAD_COMMAND git clone "--branch" "n${SM_FFMPEG_VERSION}" "--depth" "1" "git://source.ffmpeg.org/ffmpeg.git" "${SM_FFMPEG_SRC_DIR}" + DOWNLOAD_COMMAND git clone "--branch" "n${SM_FFMPEG_VERSION}" "--depth" "1" "git://github.com/stepmania/ffmpeg.git" "${SM_FFMPEG_SRC_DIR}" CONFIGURE_COMMAND "${FFMPEG_CONFIGURE}" BUILD_COMMAND "${SM_FFMPEG_MAKE}" UPDATE_COMMAND "" diff --git a/src/arch/Sound/RageSoundDriver.cpp b/src/arch/Sound/RageSoundDriver.cpp index b809c5ac04..aa13582851 100644 --- a/src/arch/Sound/RageSoundDriver.cpp +++ b/src/arch/Sound/RageSoundDriver.cpp @@ -18,13 +18,12 @@ RageSoundDriver *RageSoundDriver::Create( const RString& drivers ) else { split(drivers, ",", drivers_to_try); - vector default_drivers; - split(DEFAULT_SOUND_DRIVER_LIST, ",", default_drivers); size_t to_try= 0; bool had_to_erase= false; while(to_try < drivers_to_try.size()) { - if(std::find(default_drivers.begin(), default_drivers.end(), drivers_to_try[to_try]) == default_drivers.end()) + if(m_pDriverList.m_pRegistrees->find(istring(drivers_to_try[to_try])) + == m_pDriverList.m_pRegistrees->end()) { LOG->Warn("Removed unusable sound driver %s", drivers_to_try[to_try].c_str()); drivers_to_try.erase(drivers_to_try.begin() + to_try);