Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

[rbp] fixed protect return vales in peripherals too

  • Loading branch information...
commit bedd4afe5732bd3ad005b6e3f1d0473108565658 1 parent d9a4065
@huceke authored
Showing with 3 additions and 4 deletions.
  1. +3 −4 xbmc/peripherals/Peripherals.cpp
View
7 xbmc/peripherals/Peripherals.cpp
@@ -145,9 +145,8 @@ void CPeripherals::TriggerDeviceScan(const PeripheralBusType type /* = PERIPHERA
CPeripheralBus *CPeripherals::GetBusByType(const PeripheralBusType type) const
{
- CPeripheralBus *bus(NULL);
-
CSingleLock lock(m_critSection);
+ CPeripheralBus *bus(NULL);
for (unsigned int iBusPtr = 0; iBusPtr < m_busses.size(); iBusPtr++)
{
if (m_busses.at(iBusPtr)->Type() == type)
@@ -162,8 +161,8 @@ CPeripheralBus *CPeripherals::GetBusByType(const PeripheralBusType type) const
CPeripheral *CPeripherals::GetPeripheralAtLocation(const CStdString &strLocation, PeripheralBusType busType /* = PERIPHERAL_BUS_UNKNOWN */) const
{
- CPeripheral *peripheral(NULL);
CSingleLock lock(m_critSection);
+ CPeripheral *peripheral(NULL);
for (unsigned int iBusPtr = 0; iBusPtr < m_busses.size(); iBusPtr++)
{
/* check whether the bus matches if a bus type other than unknown was passed */
@@ -198,8 +197,8 @@ CPeripheralBus *CPeripherals::GetBusWithDevice(const CStdString &strLocation) co
int CPeripherals::GetPeripheralsWithFeature(vector<CPeripheral *> &results, const PeripheralFeature feature, PeripheralBusType busType /* = PERIPHERAL_BUS_UNKNOWN */) const
{
- int iReturn(0);
CSingleLock lock(m_critSection);
+ int iReturn(0);
for (unsigned int iBusPtr = 0; iBusPtr < m_busses.size(); iBusPtr++)
{
/* check whether the bus matches if a bus type other than unknown was passed */
Please sign in to comment.
Something went wrong with that request. Please try again.