fix card state lost when another card updates

This commit is contained in:
Glenn Maynard
2005-04-21 06:36:30 +00:00
parent f4c3c1a759
commit 88023a04db
@@ -205,9 +205,12 @@ bool MemoryCardDriverThreaded_Linux::DoOneUpdate( bool bMount, vector<UsbStorage
continue; continue;
} }
/* If the device already existed, and was set to CHECKING, check the device /* Preserve the state of the device. */
* now if we're allowed to. */ d.m_State = iter->m_State;
if( iter->m_State == UsbStorageDevice::STATE_CHECKING )
/* The device was here last time. If CHECKING, check the device now if
* we're allowed to. */
if( d.m_State == UsbStorageDevice::STATE_CHECKING )
{ {
if( !bMount ) if( !bMount )
{ {
@@ -323,7 +326,6 @@ void GetNewStorageDevices( vector<UsbStorageDevice>& vDevicesOut )
UsbStorageDevice usbd; UsbStorageDevice usbd;
CString sPath = sBlockDevicePath + asDevices[i] + "/"; CString sPath = sBlockDevicePath + asDevices[i] + "/";
LOG->Trace("'%s'", sPath.c_str());
/* Ignore non-removable devices. */ /* Ignore non-removable devices. */
CString sBuf; CString sBuf;