fix Linux compile error
This commit is contained in:
@@ -229,13 +229,18 @@ bool MemoryCardDriver_Linux::MountAndTestWrite( UsbStorageDevice* pDevice )
|
||||
return true;
|
||||
}
|
||||
|
||||
void MemoryCardDriver_Linux::Unmount( UsbStorageDevice* pDevice )
|
||||
void MemoryCardDriver_Linux::Flush( UsbStorageDevice* pDevice )
|
||||
{
|
||||
if( !pDevice->sOsMountDir.empty() )
|
||||
return;
|
||||
|
||||
// unmount and mount again. Is there a better way to flush?
|
||||
// "sync" will only flush all file systems at the same time. -Chris
|
||||
CString sCommand = "umount " + pDevice->sOsMountDir;
|
||||
LOG->Trace( "executing '%s'", sCommand.c_str() );
|
||||
system( sCommand );
|
||||
sCommand = "mount " + pDevice->sOsMountDir;
|
||||
system( sCommand );
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -11,7 +11,7 @@ public:
|
||||
virtual bool StorageDevicesChanged();
|
||||
virtual void GetStorageDevices( vector<UsbStorageDevice>& vStorageDevicesOut );
|
||||
virtual bool MountAndTestWrite( UsbStorageDevice* pDevice );
|
||||
virtual void Unmount( UsbStorageDevice* pDevice );
|
||||
virtual void Flush( UsbStorageDevice* pDevice );
|
||||
protected:
|
||||
int m_fds;
|
||||
time_t m_lastModTime;
|
||||
|
||||
@@ -10,7 +10,7 @@ public:
|
||||
virtual bool StorageDevicesChanged() { return false; };
|
||||
virtual void GetStorageDevices( vector<UsbStorageDevice>& vStorageDevicesOut ) {};
|
||||
virtual bool MountAndTestWrite( UsbStorageDevice* pDevice ) { return false; };
|
||||
virtual void Unmount( UsbStorageDevice* pDevice ) {};
|
||||
virtual void Flush( UsbStorageDevice* pDevice ) {};
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user