Another one similar.
This commit is contained in:
@@ -12,12 +12,13 @@ RageSoundDriver *RageSoundDriver::Create( const RString& sDrivers )
|
||||
vector<RString> DriversToTry;
|
||||
split( sDrivers.empty()? DEFAULT_SOUND_DRIVER_LIST:sDrivers, ",", DriversToTry, true );
|
||||
|
||||
FOREACH_CONST( RString, DriversToTry, Driver )
|
||||
for (RString const &Driver : DriversToTry)
|
||||
{
|
||||
RageDriver *pDriver = m_pDriverList.Create( *Driver );
|
||||
RageDriver *pDriver = m_pDriverList.Create( Driver );
|
||||
char const * driverString = Driver.c_str();
|
||||
if( pDriver == NULL )
|
||||
{
|
||||
LOG->Trace( "Unknown sound driver: %s", Driver->c_str() );
|
||||
LOG->Trace( "Unknown sound driver: %s", driverString );
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -27,10 +28,10 @@ RageSoundDriver *RageSoundDriver::Create( const RString& sDrivers )
|
||||
const RString sError = pRet->Init();
|
||||
if( sError.empty() )
|
||||
{
|
||||
LOG->Info( "Sound driver: %s", Driver->c_str() );
|
||||
LOG->Info( "Sound driver: %s", driverString );
|
||||
return pRet;
|
||||
}
|
||||
LOG->Info( "Couldn't load driver %s: %s", Driver->c_str(), sError.c_str() );
|
||||
LOG->Info( "Couldn't load driver %s: %s", driverString, sError.c_str() );
|
||||
SAFE_DELETE( pRet );
|
||||
}
|
||||
return NULL;
|
||||
|
||||
Reference in New Issue
Block a user