mirror of
https://github.com/akuker/RASCSI.git
synced 2024-09-29 13:54:48 +00:00
Removed useless assertions (#125)
* Removed useless assertions * Finalized removal * Pointer was passed instead of integer value * Fixed data type issue on 64 bit compile platforms * Added missing virtual destructor (gcc warning)
This commit is contained in:
parent
da3629510d
commit
6d1f661ab8
@ -1647,7 +1647,7 @@ BOOL FASTCALL SASIDEV::XferOut(BOOL cont)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
LOGTRACE("%s eCmdWriteAndVerify10 Calling Write... cmd: %02X next: %d", __PRETTY_FUNCTION__, (unsigned int)ctrl.cmd, (int)ctrl.next);
|
LOGTRACE("%s eCmdWriteAndVerify10 Calling Write... cmd: %02X next: %d", __PRETTY_FUNCTION__, (WORD)ctrl.cmd[0], (int)ctrl.next);
|
||||||
if (!ctrl.unit[lun]->Write(ctrl.cmd, ctrl.buffer, ctrl.next - 1)) {
|
if (!ctrl.unit[lun]->Write(ctrl.cmd, ctrl.buffer, ctrl.next - 1)) {
|
||||||
// Write failed
|
// Write failed
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
@ -167,7 +167,6 @@ static char* U2S(const char *utf8)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void Human68k::namests_t::GetCopyPath(BYTE* szPath) const
|
void Human68k::namests_t::GetCopyPath(BYTE* szPath) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szPath);
|
ASSERT(szPath);
|
||||||
|
|
||||||
BYTE* p = szPath;
|
BYTE* p = szPath;
|
||||||
@ -194,7 +193,6 @@ void Human68k::namests_t::GetCopyPath(BYTE* szPath) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void Human68k::namests_t::GetCopyFilename(BYTE* szFilename) const
|
void Human68k::namests_t::GetCopyFilename(BYTE* szFilename) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szFilename);
|
ASSERT(szFilename);
|
||||||
|
|
||||||
size_t i;
|
size_t i;
|
||||||
@ -310,7 +308,6 @@ CHostDrv::~CHostDrv()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::Init(const TCHAR* szBase, DWORD nFlag)
|
void CHostDrv::Init(const TCHAR* szBase, DWORD nFlag)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szBase);
|
ASSERT(szBase);
|
||||||
ASSERT(strlen(szBase) < FILEPATH_MAX);
|
ASSERT(strlen(szBase) < FILEPATH_MAX);
|
||||||
ASSERT(m_bWriteProtect == FALSE);
|
ASSERT(m_bWriteProtect == FALSE);
|
||||||
@ -363,7 +360,6 @@ void CHostDrv::Init(const TCHAR* szBase, DWORD nFlag)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostDrv::isMediaOffline()
|
BOOL CHostDrv::isMediaOffline()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// オフライン状態チェック
|
// オフライン状態チェック
|
||||||
return m_bEnable == FALSE;
|
return m_bEnable == FALSE;
|
||||||
@ -376,7 +372,6 @@ BOOL CHostDrv::isMediaOffline()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BYTE CHostDrv::GetMediaByte() const
|
BYTE CHostDrv::GetMediaByte() const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
return Human68k::MEDIA_REMOTE;
|
return Human68k::MEDIA_REMOTE;
|
||||||
}
|
}
|
||||||
@ -388,7 +383,6 @@ BYTE CHostDrv::GetMediaByte() const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
DWORD CHostDrv::GetStatus() const
|
DWORD CHostDrv::GetStatus() const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
return 0x40 | (m_bEnable ? (m_bWriteProtect ? 0x08 : 0) | 0x02 : 0);
|
return 0x40 | (m_bEnable ? (m_bWriteProtect ? 0x08 : 0) | 0x02 : 0);
|
||||||
}
|
}
|
||||||
@ -400,7 +394,6 @@ DWORD CHostDrv::GetStatus() const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::SetEnable(BOOL bEnable)
|
void CHostDrv::SetEnable(BOOL bEnable)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
m_bEnable = bEnable;
|
m_bEnable = bEnable;
|
||||||
|
|
||||||
@ -419,7 +412,6 @@ void CHostDrv::SetEnable(BOOL bEnable)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostDrv::CheckMedia()
|
BOOL CHostDrv::CheckMedia()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// 状態更新
|
// 状態更新
|
||||||
Update();
|
Update();
|
||||||
@ -436,7 +428,6 @@ BOOL CHostDrv::CheckMedia()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::Update()
|
void CHostDrv::Update()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// メディア挿入とみなす
|
// メディア挿入とみなす
|
||||||
BOOL bEnable = TRUE;
|
BOOL bEnable = TRUE;
|
||||||
@ -452,7 +443,6 @@ void CHostDrv::Update()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::Eject()
|
void CHostDrv::Eject()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// メディア排出
|
// メディア排出
|
||||||
CleanCache();
|
CleanCache();
|
||||||
@ -469,7 +459,6 @@ void CHostDrv::Eject()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::GetVolume(TCHAR* szLabel)
|
void CHostDrv::GetVolume(TCHAR* szLabel)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szLabel);
|
ASSERT(szLabel);
|
||||||
ASSERT(m_bEnable);
|
ASSERT(m_bEnable);
|
||||||
|
|
||||||
@ -502,7 +491,6 @@ void CHostDrv::GetVolume(TCHAR* szLabel)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostDrv::GetVolumeCache(TCHAR* szLabel) const
|
BOOL CHostDrv::GetVolumeCache(TCHAR* szLabel) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szLabel);
|
ASSERT(szLabel);
|
||||||
|
|
||||||
// 内容を転送
|
// 内容を転送
|
||||||
@ -518,7 +506,6 @@ BOOL CHostDrv::GetVolumeCache(TCHAR* szLabel) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
DWORD CHostDrv::GetCapacity(Human68k::capacity_t* pCapacity)
|
DWORD CHostDrv::GetCapacity(Human68k::capacity_t* pCapacity)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pCapacity);
|
ASSERT(pCapacity);
|
||||||
ASSERT(m_bEnable);
|
ASSERT(m_bEnable);
|
||||||
|
|
||||||
@ -558,7 +545,6 @@ DWORD CHostDrv::GetCapacity(Human68k::capacity_t* pCapacity)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostDrv::GetCapacityCache(Human68k::capacity_t* pCapacity) const
|
BOOL CHostDrv::GetCapacityCache(Human68k::capacity_t* pCapacity) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pCapacity);
|
ASSERT(pCapacity);
|
||||||
|
|
||||||
// 内容を転送
|
// 内容を転送
|
||||||
@ -574,7 +560,6 @@ BOOL CHostDrv::GetCapacityCache(Human68k::capacity_t* pCapacity) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::CleanCache()
|
void CHostDrv::CleanCache()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
Lock();
|
Lock();
|
||||||
for (CHostPath* p = (CHostPath*)m_cRing.Next(); p != &m_cRing;) {
|
for (CHostPath* p = (CHostPath*)m_cRing.Next(); p != &m_cRing;) {
|
||||||
@ -591,7 +576,6 @@ void CHostDrv::CleanCache()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::CleanCache(const BYTE* szHumanPath)
|
void CHostDrv::CleanCache(const BYTE* szHumanPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHumanPath);
|
ASSERT(szHumanPath);
|
||||||
|
|
||||||
Lock();
|
Lock();
|
||||||
@ -610,7 +594,6 @@ void CHostDrv::CleanCache(const BYTE* szHumanPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::CleanCacheChild(const BYTE* szHumanPath)
|
void CHostDrv::CleanCacheChild(const BYTE* szHumanPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHumanPath);
|
ASSERT(szHumanPath);
|
||||||
|
|
||||||
Lock();
|
Lock();
|
||||||
@ -630,7 +613,6 @@ void CHostDrv::CleanCacheChild(const BYTE* szHumanPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostDrv::DeleteCache(const BYTE* szHumanPath)
|
void CHostDrv::DeleteCache(const BYTE* szHumanPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHumanPath);
|
ASSERT(szHumanPath);
|
||||||
|
|
||||||
Lock();
|
Lock();
|
||||||
@ -654,7 +636,6 @@ void CHostDrv::DeleteCache(const BYTE* szHumanPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
CHostPath* CHostDrv::FindCache(const BYTE* szHuman)
|
CHostPath* CHostDrv::FindCache(const BYTE* szHuman)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHuman);
|
ASSERT(szHuman);
|
||||||
|
|
||||||
// 所持している全てのファイル名の中から完全一致するものを検索
|
// 所持している全てのファイル名の中から完全一致するものを検索
|
||||||
@ -678,7 +659,6 @@ CHostPath* CHostDrv::FindCache(const BYTE* szHuman)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
CHostPath* CHostDrv::CopyCache(CHostFiles* pFiles)
|
CHostPath* CHostDrv::CopyCache(CHostFiles* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
ASSERT(strlen((const char*)pFiles->GetHumanPath()) < HUMAN68K_PATH_MAX);
|
ASSERT(strlen((const char*)pFiles->GetHumanPath()) < HUMAN68K_PATH_MAX);
|
||||||
|
|
||||||
@ -724,7 +704,6 @@ CHostPath* CHostDrv::CopyCache(CHostFiles* pFiles)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
CHostPath* CHostDrv::MakeCache(CHostFiles* pFiles)
|
CHostPath* CHostDrv::MakeCache(CHostFiles* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
ASSERT(strlen((const char*)pFiles->GetHumanPath()) < HUMAN68K_PATH_MAX);
|
ASSERT(strlen((const char*)pFiles->GetHumanPath()) < HUMAN68K_PATH_MAX);
|
||||||
|
|
||||||
@ -838,7 +817,6 @@ CHostPath* CHostDrv::MakeCache(CHostFiles* pFiles)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostDrv::Find(CHostFiles* pFiles)
|
BOOL CHostDrv::Find(CHostFiles* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
|
|
||||||
// 排他制御開始
|
// 排他制御開始
|
||||||
@ -908,7 +886,6 @@ CHostFilename::CHostFilename()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFilename::SetHost(const TCHAR* szHost)
|
void CHostFilename::SetHost(const TCHAR* szHost)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHost);
|
ASSERT(szHost);
|
||||||
ASSERT(strlen(szHost) < FILEPATH_MAX);
|
ASSERT(strlen(szHost) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -950,7 +927,6 @@ void CHostFilename::ConvertHuman(int nCount)
|
|||||||
{
|
{
|
||||||
char szHost[FILEPATH_MAX];
|
char szHost[FILEPATH_MAX];
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// 特殊ディレクトリ名の場合は変換しない
|
// 特殊ディレクトリ名の場合は変換しない
|
||||||
if (m_szHost[0] == _T('.') &&
|
if (m_szHost[0] == _T('.') &&
|
||||||
@ -1177,7 +1153,6 @@ void CHostFilename::ConvertHuman(int nCount)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFilename::CopyHuman(const BYTE* szHuman)
|
void CHostFilename::CopyHuman(const BYTE* szHuman)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHuman);
|
ASSERT(szHuman);
|
||||||
ASSERT(strlen((const char*)szHuman) < 23);
|
ASSERT(strlen((const char*)szHuman) < 23);
|
||||||
|
|
||||||
@ -1196,7 +1171,6 @@ void CHostFilename::CopyHuman(const BYTE* szHuman)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFilename::SetEntryName()
|
void CHostFilename::SetEntryName()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// ファイル名設定
|
// ファイル名設定
|
||||||
BYTE* p = m_szHuman;
|
BYTE* p = m_szHuman;
|
||||||
@ -1232,7 +1206,6 @@ void CHostFilename::SetEntryName()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostFilename::isReduce() const
|
BOOL CHostFilename::isReduce() const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
return strcmp((LPTSTR)m_szHost, (const char*)m_szHuman) != 0; /// @warning Unicode時要修正 → 済
|
return strcmp((LPTSTR)m_szHost, (const char*)m_szHuman) != 0; /// @warning Unicode時要修正 → 済
|
||||||
}
|
}
|
||||||
@ -1244,7 +1217,6 @@ BOOL CHostFilename::isReduce() const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostFilename::CheckAttribute(DWORD nHumanAttribute) const
|
BOOL CHostFilename::CheckAttribute(DWORD nHumanAttribute) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
BYTE nAttribute = m_dirHuman.attr;
|
BYTE nAttribute = m_dirHuman.attr;
|
||||||
if ((nAttribute & (Human68k::AT_ARCHIVE | Human68k::AT_DIRECTORY | Human68k::AT_VOLUME)) == 0)
|
if ((nAttribute & (Human68k::AT_ARCHIVE | Human68k::AT_DIRECTORY | Human68k::AT_VOLUME)) == 0)
|
||||||
@ -1358,7 +1330,6 @@ void CHostPath::Free(ring_t* pRing) // static
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostPath::Clean()
|
void CHostPath::Clean()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
Release();
|
Release();
|
||||||
|
|
||||||
@ -1376,7 +1347,6 @@ void CHostPath::Clean()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostPath::SetHuman(const BYTE* szHuman)
|
void CHostPath::SetHuman(const BYTE* szHuman)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHuman);
|
ASSERT(szHuman);
|
||||||
ASSERT(strlen((const char*)szHuman) < HUMAN68K_PATH_MAX);
|
ASSERT(strlen((const char*)szHuman) < HUMAN68K_PATH_MAX);
|
||||||
|
|
||||||
@ -1390,7 +1360,6 @@ void CHostPath::SetHuman(const BYTE* szHuman)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostPath::SetHost(const TCHAR* szHost)
|
void CHostPath::SetHost(const TCHAR* szHost)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHost);
|
ASSERT(szHost);
|
||||||
ASSERT(strlen(szHost) < FILEPATH_MAX);
|
ASSERT(strlen(szHost) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -1481,7 +1450,6 @@ int CHostPath::Compare(const BYTE* pFirst, const BYTE* pLast, const BYTE* pBufFi
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostPath::isSameHuman(const BYTE* szHuman) const
|
BOOL CHostPath::isSameHuman(const BYTE* szHuman) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHuman);
|
ASSERT(szHuman);
|
||||||
|
|
||||||
// 文字数計算
|
// 文字数計算
|
||||||
@ -1503,7 +1471,6 @@ BOOL CHostPath::isSameHuman(const BYTE* szHuman) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostPath::isSameChild(const BYTE* szHuman) const
|
BOOL CHostPath::isSameChild(const BYTE* szHuman) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHuman);
|
ASSERT(szHuman);
|
||||||
|
|
||||||
// 文字数計算
|
// 文字数計算
|
||||||
@ -1529,7 +1496,6 @@ BOOL CHostPath::isSameChild(const BYTE* szHuman) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
const CHostFilename* CHostPath::FindFilename(const BYTE* szHuman, DWORD nHumanAttribute) const
|
const CHostFilename* CHostPath::FindFilename(const BYTE* szHuman, DWORD nHumanAttribute) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHuman);
|
ASSERT(szHuman);
|
||||||
|
|
||||||
// 文字数計算
|
// 文字数計算
|
||||||
@ -1569,7 +1535,6 @@ const CHostFilename* CHostPath::FindFilename(const BYTE* szHuman, DWORD nHumanAt
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
const CHostFilename* CHostPath::FindFilenameWildcard(const BYTE* szHuman, DWORD nHumanAttribute, find_t* pFind) const
|
const CHostFilename* CHostPath::FindFilenameWildcard(const BYTE* szHuman, DWORD nHumanAttribute, find_t* pFind) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHuman);
|
ASSERT(szHuman);
|
||||||
ASSERT(pFind);
|
ASSERT(pFind);
|
||||||
|
|
||||||
@ -1655,7 +1620,6 @@ const CHostFilename* CHostPath::FindFilenameWildcard(const BYTE* szHuman, DWORD
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostPath::isRefresh()
|
BOOL CHostPath::isRefresh()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
return m_bRefresh;
|
return m_bRefresh;
|
||||||
}
|
}
|
||||||
@ -1815,7 +1779,6 @@ int AsciiSort(const dirent **a, const dirent **b)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostPath::Refresh()
|
void CHostPath::Refresh()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(strlen(m_szHost) + 22 < FILEPATH_MAX);
|
ASSERT(strlen(m_szHost) + 22 < FILEPATH_MAX);
|
||||||
|
|
||||||
// タイムスタンプ保存
|
// タイムスタンプ保存
|
||||||
@ -2013,7 +1976,6 @@ void CHostPath::Refresh()
|
|||||||
void CHostPath::Backup()
|
void CHostPath::Backup()
|
||||||
{
|
{
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(m_szHost);
|
ASSERT(m_szHost);
|
||||||
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -2033,7 +1995,6 @@ void CHostPath::Backup()
|
|||||||
#else
|
#else
|
||||||
FILINFO fno;
|
FILINFO fno;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(m_szHost);
|
ASSERT(m_szHost);
|
||||||
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -2063,7 +2024,6 @@ void CHostPath::Backup()
|
|||||||
void CHostPath::Restore() const
|
void CHostPath::Restore() const
|
||||||
{
|
{
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(m_szHost);
|
ASSERT(m_szHost);
|
||||||
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -2085,7 +2045,6 @@ void CHostPath::Restore() const
|
|||||||
#else
|
#else
|
||||||
FILINFO fno;
|
FILINFO fno;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(m_szHost);
|
ASSERT(m_szHost);
|
||||||
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
ASSERT(strlen(m_szHost) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -2113,7 +2072,6 @@ void CHostPath::Restore() const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostPath::Release()
|
void CHostPath::Release()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
m_bRefresh = TRUE;
|
m_bRefresh = TRUE;
|
||||||
}
|
}
|
||||||
@ -2162,7 +2120,6 @@ CHostEntry::~CHostEntry()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::Init()
|
void CHostEntry::Init()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
// オブジェクト確認
|
// オブジェクト確認
|
||||||
@ -2179,7 +2136,6 @@ void CHostEntry::Init()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::Clean()
|
void CHostEntry::Clean()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// オブジェクト削除
|
// オブジェクト削除
|
||||||
for (size_t n = 0; n < DriveMax; n++) {
|
for (size_t n = 0; n < DriveMax; n++) {
|
||||||
@ -2195,7 +2151,6 @@ void CHostEntry::Clean()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::CleanCache()
|
void CHostEntry::CleanCache()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
for (size_t i = 0; i < DriveMax; i++) {
|
for (size_t i = 0; i < DriveMax; i++) {
|
||||||
if (m_pDrv[i])
|
if (m_pDrv[i])
|
||||||
@ -2212,7 +2167,6 @@ void CHostEntry::CleanCache()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::CleanCache(DWORD nUnit)
|
void CHostEntry::CleanCache(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2226,7 +2180,6 @@ void CHostEntry::CleanCache(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::CleanCache(DWORD nUnit, const BYTE* szHumanPath)
|
void CHostEntry::CleanCache(DWORD nUnit, const BYTE* szHumanPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHumanPath);
|
ASSERT(szHumanPath);
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
@ -2241,7 +2194,6 @@ void CHostEntry::CleanCache(DWORD nUnit, const BYTE* szHumanPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::CleanCacheChild(DWORD nUnit, const BYTE* szHumanPath)
|
void CHostEntry::CleanCacheChild(DWORD nUnit, const BYTE* szHumanPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHumanPath);
|
ASSERT(szHumanPath);
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
@ -2256,7 +2208,6 @@ void CHostEntry::CleanCacheChild(DWORD nUnit, const BYTE* szHumanPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::DeleteCache(DWORD nUnit, const BYTE* szHumanPath)
|
void CHostEntry::DeleteCache(DWORD nUnit, const BYTE* szHumanPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHumanPath);
|
ASSERT(szHumanPath);
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
@ -2271,7 +2222,6 @@ void CHostEntry::DeleteCache(DWORD nUnit, const BYTE* szHumanPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostEntry::Find(DWORD nUnit, CHostFiles* pFiles)
|
BOOL CHostEntry::Find(DWORD nUnit, CHostFiles* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
@ -2288,7 +2238,6 @@ void CHostEntry::ShellNotify(DWORD, const TCHAR*) {}
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::SetDrv(DWORD nUnit, CHostDrv* pDrv)
|
void CHostEntry::SetDrv(DWORD nUnit, CHostDrv* pDrv)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit] == NULL);
|
ASSERT(m_pDrv[nUnit] == NULL);
|
||||||
|
|
||||||
@ -2302,7 +2251,6 @@ void CHostEntry::SetDrv(DWORD nUnit, CHostDrv* pDrv)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostEntry::isWriteProtect(DWORD nUnit) const
|
BOOL CHostEntry::isWriteProtect(DWORD nUnit) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2316,7 +2264,6 @@ BOOL CHostEntry::isWriteProtect(DWORD nUnit) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostEntry::isEnable(DWORD nUnit) const
|
BOOL CHostEntry::isEnable(DWORD nUnit) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2330,7 +2277,6 @@ BOOL CHostEntry::isEnable(DWORD nUnit) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostEntry::isMediaOffline(DWORD nUnit)
|
BOOL CHostEntry::isMediaOffline(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2344,7 +2290,6 @@ BOOL CHostEntry::isMediaOffline(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BYTE CHostEntry::GetMediaByte(DWORD nUnit) const
|
BYTE CHostEntry::GetMediaByte(DWORD nUnit) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2358,7 +2303,6 @@ BYTE CHostEntry::GetMediaByte(DWORD nUnit) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
DWORD CHostEntry::GetStatus(DWORD nUnit) const
|
DWORD CHostEntry::GetStatus(DWORD nUnit) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2372,7 +2316,6 @@ DWORD CHostEntry::GetStatus(DWORD nUnit) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostEntry::CheckMedia(DWORD nUnit)
|
BOOL CHostEntry::CheckMedia(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2386,7 +2329,6 @@ BOOL CHostEntry::CheckMedia(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::Eject(DWORD nUnit)
|
void CHostEntry::Eject(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2400,7 +2342,6 @@ void CHostEntry::Eject(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostEntry::GetVolume(DWORD nUnit, TCHAR* szLabel)
|
void CHostEntry::GetVolume(DWORD nUnit, TCHAR* szLabel)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2414,7 +2355,6 @@ void CHostEntry::GetVolume(DWORD nUnit, TCHAR* szLabel)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostEntry::GetVolumeCache(DWORD nUnit, TCHAR* szLabel) const
|
BOOL CHostEntry::GetVolumeCache(DWORD nUnit, TCHAR* szLabel) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2428,7 +2368,6 @@ BOOL CHostEntry::GetVolumeCache(DWORD nUnit, TCHAR* szLabel) const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
DWORD CHostEntry::GetCapacity(DWORD nUnit, Human68k::capacity_t* pCapacity)
|
DWORD CHostEntry::GetCapacity(DWORD nUnit, Human68k::capacity_t* pCapacity)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2442,7 +2381,6 @@ DWORD CHostEntry::GetCapacity(DWORD nUnit, Human68k::capacity_t* pCapacity)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostEntry::GetCapacityCache(DWORD nUnit, Human68k::capacity_t* pCapacity) const
|
BOOL CHostEntry::GetCapacityCache(DWORD nUnit, Human68k::capacity_t* pCapacity) const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nUnit < DriveMax);
|
ASSERT(nUnit < DriveMax);
|
||||||
ASSERT(m_pDrv[nUnit]);
|
ASSERT(m_pDrv[nUnit]);
|
||||||
|
|
||||||
@ -2517,7 +2455,6 @@ const BYTE* CHostDrv::SeparateCopyFilename(const BYTE* szHuman, BYTE* szBuffer)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFiles::Init()
|
void CHostFiles::Init()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
@ -2527,7 +2464,6 @@ void CHostFiles::Init()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFiles::SetPath(const Human68k::namests_t* pNamests)
|
void CHostFiles::SetPath(const Human68k::namests_t* pNamests)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
|
|
||||||
pNamests->GetCopyPath(m_szHumanPath);
|
pNamests->GetCopyPath(m_szHumanPath);
|
||||||
@ -2544,7 +2480,6 @@ void CHostFiles::SetPath(const Human68k::namests_t* pNamests)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostFiles::Find(DWORD nUnit, CHostEntry* pEntry)
|
BOOL CHostFiles::Find(DWORD nUnit, CHostEntry* pEntry)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pEntry);
|
ASSERT(pEntry);
|
||||||
|
|
||||||
return pEntry->Find(nUnit, this);
|
return pEntry->Find(nUnit, this);
|
||||||
@ -2557,7 +2492,6 @@ BOOL CHostFiles::Find(DWORD nUnit, CHostEntry* pEntry)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
const CHostFilename* CHostFiles::Find(CHostPath* pPath)
|
const CHostFilename* CHostFiles::Find(CHostPath* pPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pPath);
|
ASSERT(pPath);
|
||||||
|
|
||||||
if (m_nHumanWildcard)
|
if (m_nHumanWildcard)
|
||||||
@ -2573,7 +2507,6 @@ const CHostFilename* CHostFiles::Find(CHostPath* pPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFiles::SetEntry(const CHostFilename* pFilename)
|
void CHostFiles::SetEntry(const CHostFilename* pFilename)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFilename);
|
ASSERT(pFilename);
|
||||||
|
|
||||||
// Human68kディレクトリエントリ保存
|
// Human68kディレクトリエントリ保存
|
||||||
@ -2590,7 +2523,6 @@ void CHostFiles::SetEntry(const CHostFilename* pFilename)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFiles::SetResult(const TCHAR* szPath)
|
void CHostFiles::SetResult(const TCHAR* szPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szPath);
|
ASSERT(szPath);
|
||||||
ASSERT(strlen(szPath) < FILEPATH_MAX);
|
ASSERT(strlen(szPath) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -2604,7 +2536,6 @@ void CHostFiles::SetResult(const TCHAR* szPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFiles::AddResult(const TCHAR* szPath)
|
void CHostFiles::AddResult(const TCHAR* szPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szPath);
|
ASSERT(szPath);
|
||||||
ASSERT(strlen(m_szHostResult) + strlen(szPath) < FILEPATH_MAX);
|
ASSERT(strlen(m_szHostResult) + strlen(szPath) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -2618,7 +2549,6 @@ void CHostFiles::AddResult(const TCHAR* szPath)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFiles::AddFilename()
|
void CHostFiles::AddFilename()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(strlen(m_szHostResult) + strlen((const char*)m_szHumanFilename) < FILEPATH_MAX);
|
ASSERT(strlen(m_szHostResult) + strlen((const char*)m_szHumanFilename) < FILEPATH_MAX);
|
||||||
/// @warning Unicode未対応。いずれUnicodeの世界に飮まれた時はここで変換を行なう → 済
|
/// @warning Unicode未対応。いずれUnicodeの世界に飮まれた時はここで変換を行なう → 済
|
||||||
strncat(m_szHostResult, (const char*)m_szHumanFilename, ARRAY_SIZE(m_szHumanFilename));
|
strncat(m_szHostResult, (const char*)m_szHumanFilename, ARRAY_SIZE(m_szHumanFilename));
|
||||||
@ -2651,7 +2581,6 @@ CHostFilesManager::~CHostFilesManager()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFilesManager::Init()
|
void CHostFilesManager::Init()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// 実体が存在しないことを確認 (念のため)
|
// 実体が存在しないことを確認 (念のため)
|
||||||
ASSERT(m_cRing.Next() == &m_cRing);
|
ASSERT(m_cRing.Next() == &m_cRing);
|
||||||
@ -2672,7 +2601,6 @@ void CHostFilesManager::Init()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFilesManager::Clean()
|
void CHostFilesManager::Clean()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// メモリ解放
|
// メモリ解放
|
||||||
CRing* p;
|
CRing* p;
|
||||||
@ -2688,7 +2616,6 @@ void CHostFilesManager::Clean()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
CHostFiles* CHostFilesManager::Alloc(DWORD nKey)
|
CHostFiles* CHostFilesManager::Alloc(DWORD nKey)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
|
|
||||||
// 末尾から選択
|
// 末尾から選択
|
||||||
@ -2710,7 +2637,6 @@ CHostFiles* CHostFilesManager::Alloc(DWORD nKey)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
CHostFiles* CHostFilesManager::Search(DWORD nKey)
|
CHostFiles* CHostFilesManager::Search(DWORD nKey)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
// ASSERT(nKey); // DPB破損により検索キーが0になることもある
|
// ASSERT(nKey); // DPB破損により検索キーが0になることもある
|
||||||
|
|
||||||
// 該当するオブジェクトを検索
|
// 該当するオブジェクトを検索
|
||||||
@ -2733,7 +2659,6 @@ CHostFiles* CHostFilesManager::Search(DWORD nKey)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFilesManager::Free(CHostFiles* pFiles)
|
void CHostFilesManager::Free(CHostFiles* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
|
|
||||||
// 解放
|
// 解放
|
||||||
@ -2758,7 +2683,6 @@ void CHostFilesManager::Free(CHostFiles* pFiles)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFcb::Init()
|
void CHostFcb::Init()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
m_bUpdate = FALSE;
|
m_bUpdate = FALSE;
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
@ -2775,7 +2699,6 @@ void CHostFcb::Init()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostFcb::SetMode(DWORD nHumanMode)
|
BOOL CHostFcb::SetMode(DWORD nHumanMode)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
switch (nHumanMode & Human68k::OP_MASK) {
|
switch (nHumanMode & Human68k::OP_MASK) {
|
||||||
@ -2819,7 +2742,6 @@ BOOL CHostFcb::SetMode(DWORD nHumanMode)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFcb::SetFilename(const TCHAR* szFilename)
|
void CHostFcb::SetFilename(const TCHAR* szFilename)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szFilename);
|
ASSERT(szFilename);
|
||||||
ASSERT(strlen(szFilename) < FILEPATH_MAX);
|
ASSERT(strlen(szFilename) < FILEPATH_MAX);
|
||||||
|
|
||||||
@ -2833,7 +2755,6 @@ void CHostFcb::SetFilename(const TCHAR* szFilename)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFcb::SetHumanPath(const BYTE* szHumanPath)
|
void CHostFcb::SetHumanPath(const BYTE* szHumanPath)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(szHumanPath);
|
ASSERT(szHumanPath);
|
||||||
ASSERT(strlen((const char*)szHumanPath) < HUMAN68K_PATH_MAX);
|
ASSERT(strlen((const char*)szHumanPath) < HUMAN68K_PATH_MAX);
|
||||||
|
|
||||||
@ -2850,7 +2771,6 @@ void CHostFcb::SetHumanPath(const BYTE* szHumanPath)
|
|||||||
BOOL CHostFcb::Create(Human68k::fcb_t* pFcb, DWORD nHumanAttribute, BOOL bForce)
|
BOOL CHostFcb::Create(Human68k::fcb_t* pFcb, DWORD nHumanAttribute, BOOL bForce)
|
||||||
{
|
{
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(this);
|
|
||||||
ASSERT((nHumanAttribute & (Human68k::AT_DIRECTORY | Human68k::AT_VOLUME)) == 0);
|
ASSERT((nHumanAttribute & (Human68k::AT_DIRECTORY | Human68k::AT_VOLUME)) == 0);
|
||||||
ASSERT(strlen(m_szFilename) > 0);
|
ASSERT(strlen(m_szFilename) > 0);
|
||||||
ASSERT(m_pFile == NULL);
|
ASSERT(m_pFile == NULL);
|
||||||
@ -2869,7 +2789,6 @@ BOOL CHostFcb::Create(Human68k::fcb_t* pFcb, DWORD nHumanAttribute, BOOL bForce)
|
|||||||
#else
|
#else
|
||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT((nHumanAttribute & (Human68k::AT_DIRECTORY | Human68k::AT_VOLUME)) == 0);
|
ASSERT((nHumanAttribute & (Human68k::AT_DIRECTORY | Human68k::AT_VOLUME)) == 0);
|
||||||
ASSERT(strlen(m_szFilename) > 0);
|
ASSERT(strlen(m_szFilename) > 0);
|
||||||
|
|
||||||
@ -2903,7 +2822,6 @@ BOOL CHostFcb::Open()
|
|||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
struct stat st;
|
struct stat st;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(strlen(m_szFilename) > 0);
|
ASSERT(strlen(m_szFilename) > 0);
|
||||||
|
|
||||||
// ディレクトリなら失敗
|
// ディレクトリなら失敗
|
||||||
@ -2922,7 +2840,6 @@ BOOL CHostFcb::Open()
|
|||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
FILINFO fno;
|
FILINFO fno;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(strlen(m_szFilename) > 0);
|
ASSERT(strlen(m_szFilename) > 0);
|
||||||
|
|
||||||
// ディレクトリなら失敗
|
// ディレクトリなら失敗
|
||||||
@ -2950,7 +2867,6 @@ BOOL CHostFcb::Open()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostFcb::Rewind(DWORD nOffset)
|
BOOL CHostFcb::Rewind(DWORD nOffset)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(m_pFile);
|
ASSERT(m_pFile);
|
||||||
|
|
||||||
@ -2977,7 +2893,6 @@ BOOL CHostFcb::Rewind(DWORD nOffset)
|
|||||||
DWORD CHostFcb::Read(BYTE* pBuffer, DWORD nSize)
|
DWORD CHostFcb::Read(BYTE* pBuffer, DWORD nSize)
|
||||||
{
|
{
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pBuffer);
|
ASSERT(pBuffer);
|
||||||
ASSERT(m_pFile);
|
ASSERT(m_pFile);
|
||||||
|
|
||||||
@ -2990,7 +2905,6 @@ DWORD CHostFcb::Read(BYTE* pBuffer, DWORD nSize)
|
|||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
UINT nResult;
|
UINT nResult;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pBuffer);
|
ASSERT(pBuffer);
|
||||||
|
|
||||||
fr = f_read(&m_File, pBuffer, nSize, &nResult);
|
fr = f_read(&m_File, pBuffer, nSize, &nResult);
|
||||||
@ -3012,7 +2926,6 @@ DWORD CHostFcb::Read(BYTE* pBuffer, DWORD nSize)
|
|||||||
DWORD CHostFcb::Write(const BYTE* pBuffer, DWORD nSize)
|
DWORD CHostFcb::Write(const BYTE* pBuffer, DWORD nSize)
|
||||||
{
|
{
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pBuffer);
|
ASSERT(pBuffer);
|
||||||
ASSERT(m_pFile);
|
ASSERT(m_pFile);
|
||||||
|
|
||||||
@ -3025,7 +2938,6 @@ DWORD CHostFcb::Write(const BYTE* pBuffer, DWORD nSize)
|
|||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
UINT nResult;
|
UINT nResult;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pBuffer);
|
ASSERT(pBuffer);
|
||||||
|
|
||||||
fr = f_write(&m_File, pBuffer, nSize, &nResult);
|
fr = f_write(&m_File, pBuffer, nSize, &nResult);
|
||||||
@ -3045,7 +2957,6 @@ DWORD CHostFcb::Write(const BYTE* pBuffer, DWORD nSize)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostFcb::Truncate()
|
BOOL CHostFcb::Truncate()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(m_pFile);
|
ASSERT(m_pFile);
|
||||||
|
|
||||||
@ -3065,7 +2976,6 @@ BOOL CHostFcb::Truncate()
|
|||||||
DWORD CHostFcb::Seek(DWORD nOffset, DWORD nHumanSeek)
|
DWORD CHostFcb::Seek(DWORD nOffset, DWORD nHumanSeek)
|
||||||
{
|
{
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nHumanSeek == Human68k::SK_BEGIN ||
|
ASSERT(nHumanSeek == Human68k::SK_BEGIN ||
|
||||||
nHumanSeek == Human68k::SK_CURRENT || nHumanSeek == Human68k::SK_END);
|
nHumanSeek == Human68k::SK_CURRENT || nHumanSeek == Human68k::SK_END);
|
||||||
ASSERT(m_pFile);
|
ASSERT(m_pFile);
|
||||||
@ -3090,7 +3000,6 @@ DWORD CHostFcb::Seek(DWORD nOffset, DWORD nHumanSeek)
|
|||||||
#else
|
#else
|
||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nHumanSeek == Human68k::SK_BEGIN ||
|
ASSERT(nHumanSeek == Human68k::SK_BEGIN ||
|
||||||
nHumanSeek == Human68k::SK_CURRENT || nHumanSeek == Human68k::SK_END);
|
nHumanSeek == Human68k::SK_CURRENT || nHumanSeek == Human68k::SK_END);
|
||||||
|
|
||||||
@ -3123,7 +3032,6 @@ DWORD CHostFcb::Seek(DWORD nOffset, DWORD nHumanSeek)
|
|||||||
BOOL CHostFcb::TimeStamp(DWORD nHumanTime)
|
BOOL CHostFcb::TimeStamp(DWORD nHumanTime)
|
||||||
{
|
{
|
||||||
#ifndef BAREMETAL
|
#ifndef BAREMETAL
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(m_pFile || m_bFlag);
|
ASSERT(m_pFile || m_bFlag);
|
||||||
|
|
||||||
struct tm t = { 0 };
|
struct tm t = { 0 };
|
||||||
@ -3148,7 +3056,6 @@ BOOL CHostFcb::TimeStamp(DWORD nHumanTime)
|
|||||||
#else
|
#else
|
||||||
FILINFO fno;
|
FILINFO fno;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(m_bFlag);
|
ASSERT(m_bFlag);
|
||||||
|
|
||||||
// クローズ時に更新時刻が上書きされるのを防止するため
|
// クローズ時に更新時刻が上書きされるのを防止するため
|
||||||
@ -3170,7 +3077,6 @@ BOOL CHostFcb::TimeStamp(DWORD nHumanTime)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CHostFcb::Close()
|
BOOL CHostFcb::Close()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
BOOL bResult = TRUE;
|
BOOL bResult = TRUE;
|
||||||
|
|
||||||
@ -3215,7 +3121,6 @@ CHostFcbManager::~CHostFcbManager()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFcbManager::Init()
|
void CHostFcbManager::Init()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// 実体が存在しないことを確認 (念のため)
|
// 実体が存在しないことを確認 (念のため)
|
||||||
ASSERT(m_cRing.Next() == &m_cRing);
|
ASSERT(m_cRing.Next() == &m_cRing);
|
||||||
@ -3236,7 +3141,6 @@ void CHostFcbManager::Init()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFcbManager::Clean()
|
void CHostFcbManager::Clean()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// メモリ解放
|
// メモリ解放
|
||||||
CRing* p;
|
CRing* p;
|
||||||
@ -3252,7 +3156,6 @@ void CHostFcbManager::Clean()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
CHostFcb* CHostFcbManager::Alloc(DWORD nKey)
|
CHostFcb* CHostFcbManager::Alloc(DWORD nKey)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
|
|
||||||
// 末尾から選択
|
// 末尾から選択
|
||||||
@ -3280,7 +3183,6 @@ CHostFcb* CHostFcbManager::Alloc(DWORD nKey)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
CHostFcb* CHostFcbManager::Search(DWORD nKey)
|
CHostFcb* CHostFcbManager::Search(DWORD nKey)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
|
|
||||||
// 該当するオブジェクトを検索
|
// 該当するオブジェクトを検索
|
||||||
@ -3304,7 +3206,6 @@ CHostFcb* CHostFcbManager::Search(DWORD nKey)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CHostFcbManager::Free(CHostFcb* pFcb)
|
void CHostFcbManager::Free(CHostFcb* pFcb)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFcb);
|
ASSERT(pFcb);
|
||||||
|
|
||||||
// 解放
|
// 解放
|
||||||
@ -3361,7 +3262,6 @@ CFileSys::CFileSys()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CFileSys::Reset()
|
void CFileSys::Reset()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// 仮想セクタ領域初期化
|
// 仮想セクタ領域初期化
|
||||||
m_nHostSectorCount = 0;
|
m_nHostSectorCount = 0;
|
||||||
@ -3391,7 +3291,6 @@ void CFileSys::Reset()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CFileSys::Init()
|
void CFileSys::Init()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// ファイル検索領域 初期化 (デバイス起動・ロード時)
|
// ファイル検索領域 初期化 (デバイス起動・ロード時)
|
||||||
m_cFiles.Init();
|
m_cFiles.Init();
|
||||||
@ -3440,7 +3339,6 @@ void CFileSys::Init()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
DWORD CFileSys::InitDevice(const Human68k::argument_t* pArgument)
|
DWORD CFileSys::InitDevice(const Human68k::argument_t* pArgument)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// オプション初期化
|
// オプション初期化
|
||||||
InitOption(pArgument);
|
InitOption(pArgument);
|
||||||
@ -3458,7 +3356,6 @@ DWORD CFileSys::InitDevice(const Human68k::argument_t* pArgument)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::CheckDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
int CFileSys::CheckDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -3486,7 +3383,6 @@ int CFileSys::CheckDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::MakeDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
int CFileSys::MakeDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -3533,7 +3429,6 @@ int CFileSys::MakeDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::RemoveDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
int CFileSys::RemoveDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -3588,7 +3483,6 @@ int CFileSys::RemoveDir(DWORD nUnit, const Human68k::namests_t* pNamests)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Rename(DWORD nUnit, const Human68k::namests_t* pNamests, const Human68k::namests_t* pNamestsNew)
|
int CFileSys::Rename(DWORD nUnit, const Human68k::namests_t* pNamests, const Human68k::namests_t* pNamestsNew)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -3651,7 +3545,6 @@ int CFileSys::Rename(DWORD nUnit, const Human68k::namests_t* pNamests, const Hum
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Delete(DWORD nUnit, const Human68k::namests_t* pNamests)
|
int CFileSys::Delete(DWORD nUnit, const Human68k::namests_t* pNamests)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -3696,7 +3589,6 @@ int CFileSys::Delete(DWORD nUnit, const Human68k::namests_t* pNamests)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Attribute(DWORD nUnit, const Human68k::namests_t* pNamests, DWORD nHumanAttribute)
|
int CFileSys::Attribute(DWORD nUnit, const Human68k::namests_t* pNamests, DWORD nHumanAttribute)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -3775,7 +3667,6 @@ int CFileSys::Attribute(DWORD nUnit, const Human68k::namests_t* pNamests, DWORD
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Files(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests, Human68k::files_t* pFiles)
|
int CFileSys::Files(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests, Human68k::files_t* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
@ -3869,7 +3760,6 @@ int CFileSys::Files(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::NFiles(DWORD nUnit, DWORD nKey, Human68k::files_t* pFiles)
|
int CFileSys::NFiles(DWORD nUnit, DWORD nKey, Human68k::files_t* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
|
|
||||||
@ -3914,7 +3804,6 @@ int CFileSys::NFiles(DWORD nUnit, DWORD nKey, Human68k::files_t* pFiles)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Create(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests, Human68k::fcb_t* pFcb, DWORD nHumanAttribute, BOOL bForce)
|
int CFileSys::Create(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests, Human68k::fcb_t* pFcb, DWORD nHumanAttribute, BOOL bForce)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
ASSERT(pFcb);
|
ASSERT(pFcb);
|
||||||
@ -3983,7 +3872,6 @@ int CFileSys::Create(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamest
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Open(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests, Human68k::fcb_t* pFcb)
|
int CFileSys::Open(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests, Human68k::fcb_t* pFcb)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pNamests);
|
ASSERT(pNamests);
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
ASSERT(pFcb);
|
ASSERT(pFcb);
|
||||||
@ -4053,7 +3941,6 @@ int CFileSys::Open(DWORD nUnit, DWORD nKey, const Human68k::namests_t* pNamests,
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Close(DWORD nUnit, DWORD nKey, Human68k::fcb_t* /* pFcb */)
|
int CFileSys::Close(DWORD nUnit, DWORD nKey, Human68k::fcb_t* /* pFcb */)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -4092,7 +3979,6 @@ int CFileSys::Close(DWORD nUnit, DWORD nKey, Human68k::fcb_t* /* pFcb */)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Read(DWORD nKey, Human68k::fcb_t* pFcb, BYTE* pBuffer, DWORD nSize)
|
int CFileSys::Read(DWORD nKey, Human68k::fcb_t* pFcb, BYTE* pBuffer, DWORD nSize)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
ASSERT(pFcb);
|
ASSERT(pFcb);
|
||||||
// ASSERT(pBuffer); // 必要時のみ判定
|
// ASSERT(pBuffer); // 必要時のみ判定
|
||||||
@ -4133,7 +4019,6 @@ int CFileSys::Read(DWORD nKey, Human68k::fcb_t* pFcb, BYTE* pBuffer, DWORD nSize
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Write(DWORD nKey, Human68k::fcb_t* pFcb, const BYTE* pBuffer, DWORD nSize)
|
int CFileSys::Write(DWORD nKey, Human68k::fcb_t* pFcb, const BYTE* pBuffer, DWORD nSize)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
ASSERT(pFcb);
|
ASSERT(pFcb);
|
||||||
// ASSERT(pBuffer); // 必要時のみ判定
|
// ASSERT(pBuffer); // 必要時のみ判定
|
||||||
@ -4192,7 +4077,6 @@ int CFileSys::Write(DWORD nKey, Human68k::fcb_t* pFcb, const BYTE* pBuffer, DWOR
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Seek(DWORD nKey, Human68k::fcb_t* pFcb, DWORD nSeek, int nOffset)
|
int CFileSys::Seek(DWORD nKey, Human68k::fcb_t* pFcb, DWORD nSeek, int nOffset)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFcb);
|
ASSERT(pFcb);
|
||||||
|
|
||||||
// 既に同じキーを持つ領域がなければエラーとする
|
// 既に同じキーを持つ領域がなければエラーとする
|
||||||
@ -4228,7 +4112,6 @@ int CFileSys::Seek(DWORD nKey, Human68k::fcb_t* pFcb, DWORD nSeek, int nOffset)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
DWORD CFileSys::TimeStamp(DWORD nUnit, DWORD nKey, Human68k::fcb_t* pFcb, DWORD nHumanTime)
|
DWORD CFileSys::TimeStamp(DWORD nUnit, DWORD nKey, Human68k::fcb_t* pFcb, DWORD nHumanTime)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(nKey);
|
ASSERT(nKey);
|
||||||
ASSERT(pFcb);
|
ASSERT(pFcb);
|
||||||
|
|
||||||
@ -4277,7 +4160,6 @@ DWORD CFileSys::TimeStamp(DWORD nUnit, DWORD nKey, Human68k::fcb_t* pFcb, DWORD
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::GetCapacity(DWORD nUnit, Human68k::capacity_t* pCapacity)
|
int CFileSys::GetCapacity(DWORD nUnit, Human68k::capacity_t* pCapacity)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pCapacity);
|
ASSERT(pCapacity);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -4302,7 +4184,6 @@ int CFileSys::GetCapacity(DWORD nUnit, Human68k::capacity_t* pCapacity)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::CtrlDrive(DWORD nUnit, Human68k::ctrldrive_t* pCtrlDrive)
|
int CFileSys::CtrlDrive(DWORD nUnit, Human68k::ctrldrive_t* pCtrlDrive)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pCtrlDrive);
|
ASSERT(pCtrlDrive);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -4343,7 +4224,6 @@ int CFileSys::CtrlDrive(DWORD nUnit, Human68k::ctrldrive_t* pCtrlDrive)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::GetDPB(DWORD nUnit, Human68k::dpb_t* pDpb)
|
int CFileSys::GetDPB(DWORD nUnit, Human68k::dpb_t* pDpb)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pDpb);
|
ASSERT(pDpb);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -4424,7 +4304,6 @@ int CFileSys::GetDPB(DWORD nUnit, Human68k::dpb_t* pDpb)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::DiskRead(DWORD nUnit, BYTE* pBuffer, DWORD nSector, DWORD nSize)
|
int CFileSys::DiskRead(DWORD nUnit, BYTE* pBuffer, DWORD nSector, DWORD nSize)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pBuffer);
|
ASSERT(pBuffer);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -4507,7 +4386,6 @@ int CFileSys::DiskRead(DWORD nUnit, BYTE* pBuffer, DWORD nSector, DWORD nSize)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::DiskWrite(DWORD nUnit)
|
int CFileSys::DiskWrite(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
if (nUnit >= DriveMax)
|
if (nUnit >= DriveMax)
|
||||||
@ -4535,7 +4413,6 @@ int CFileSys::DiskWrite(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Ioctrl(DWORD nUnit, DWORD nFunction, Human68k::ioctrl_t* pIoctrl)
|
int CFileSys::Ioctrl(DWORD nUnit, DWORD nFunction, Human68k::ioctrl_t* pIoctrl)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pIoctrl);
|
ASSERT(pIoctrl);
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
@ -4595,7 +4472,6 @@ int CFileSys::Ioctrl(DWORD nUnit, DWORD nFunction, Human68k::ioctrl_t* pIoctrl)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Flush(DWORD nUnit)
|
int CFileSys::Flush(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
if (nUnit >= DriveMax)
|
if (nUnit >= DriveMax)
|
||||||
@ -4614,7 +4490,6 @@ int CFileSys::Flush(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::CheckMedia(DWORD nUnit)
|
int CFileSys::CheckMedia(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
if (nUnit >= DriveMax)
|
if (nUnit >= DriveMax)
|
||||||
@ -4640,7 +4515,6 @@ int CFileSys::CheckMedia(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int CFileSys::Lock(DWORD nUnit)
|
int CFileSys::Lock(DWORD nUnit)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// ユニットチェック
|
// ユニットチェック
|
||||||
if (nUnit >= DriveMax)
|
if (nUnit >= DriveMax)
|
||||||
@ -4664,7 +4538,6 @@ int CFileSys::Lock(DWORD nUnit)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CFileSys::SetOption(DWORD nOption)
|
void CFileSys::SetOption(DWORD nOption)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// オプション設定変更でキャッシュクリア
|
// オプション設定変更でキャッシュクリア
|
||||||
if (m_nOption ^ nOption)
|
if (m_nOption ^ nOption)
|
||||||
@ -4681,7 +4554,6 @@ void CFileSys::SetOption(DWORD nOption)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void CFileSys::InitOption(const Human68k::argument_t* pArgument)
|
void CFileSys::InitOption(const Human68k::argument_t* pArgument)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pArgument);
|
ASSERT(pArgument);
|
||||||
|
|
||||||
// ドライブ数を初期化
|
// ドライブ数を初期化
|
||||||
@ -4766,7 +4638,6 @@ void CFileSys::InitOption(const Human68k::argument_t* pArgument)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL CFileSys::FilesVolume(DWORD nUnit, Human68k::files_t* pFiles)
|
BOOL CFileSys::FilesVolume(DWORD nUnit, Human68k::files_t* pFiles)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(pFiles);
|
ASSERT(pFiles);
|
||||||
|
|
||||||
// ボリュームラベル取得
|
// ボリュームラベル取得
|
||||||
|
@ -373,15 +373,14 @@ public:
|
|||||||
// 基本ファンクション
|
// 基本ファンクション
|
||||||
CRing() { Init(); } ///< デフォルトコンストラクタ
|
CRing() { Init(); } ///< デフォルトコンストラクタ
|
||||||
~CRing() { Remove(); } ///< デストラクタ final
|
~CRing() { Remove(); } ///< デストラクタ final
|
||||||
void Init() { ASSERT(this); next = prev = this; } ///< 初期化
|
void Init() { next = prev = this; } ///< 初期化
|
||||||
|
|
||||||
CRing* Next() const { ASSERT(this); return next; } ///< 次の要素を取得
|
CRing* Next() const { return next; } ///< 次の要素を取得
|
||||||
CRing* Prev() const { ASSERT(this); return prev; } ///< 前の要素を取得
|
CRing* Prev() const { return prev; } ///< 前の要素を取得
|
||||||
|
|
||||||
void Insert(CRing* pRoot)
|
void Insert(CRing* pRoot)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
// 該当オブジェクトを切り離し
|
||||||
// 該当オブジェクトを切り離し
|
|
||||||
ASSERT(next);
|
ASSERT(next);
|
||||||
ASSERT(prev);
|
ASSERT(prev);
|
||||||
next->prev = prev;
|
next->prev = prev;
|
||||||
@ -398,8 +397,7 @@ public:
|
|||||||
|
|
||||||
void InsertTail(CRing* pRoot)
|
void InsertTail(CRing* pRoot)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
// 該当オブジェクトを切り離し
|
||||||
// 該当オブジェクトを切り離し
|
|
||||||
ASSERT(next);
|
ASSERT(next);
|
||||||
ASSERT(prev);
|
ASSERT(prev);
|
||||||
next->prev = prev;
|
next->prev = prev;
|
||||||
@ -416,8 +414,7 @@ public:
|
|||||||
|
|
||||||
void InsertRing(CRing* pRoot)
|
void InsertRing(CRing* pRoot)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
if (next == prev) return;
|
||||||
if (next == prev) return;
|
|
||||||
|
|
||||||
// リング先頭へ挿入
|
// リング先頭へ挿入
|
||||||
ASSERT(pRoot);
|
ASSERT(pRoot);
|
||||||
@ -434,8 +431,7 @@ public:
|
|||||||
|
|
||||||
void Remove()
|
void Remove()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
// 該当オブジェクトを切り離し
|
||||||
// 該当オブジェクトを切り離し
|
|
||||||
ASSERT(next);
|
ASSERT(next);
|
||||||
ASSERT(prev);
|
ASSERT(prev);
|
||||||
next->prev = prev;
|
next->prev = prev;
|
||||||
@ -462,31 +458,31 @@ public:
|
|||||||
static size_t Offset() { return offsetof(CHostFilename, m_szHost); } ///< オフセット位置取得
|
static size_t Offset() { return offsetof(CHostFilename, m_szHost); } ///< オフセット位置取得
|
||||||
|
|
||||||
void SetHost(const TCHAR* szHost); ///< ホスト側の名称を設定
|
void SetHost(const TCHAR* szHost); ///< ホスト側の名称を設定
|
||||||
const TCHAR* GetHost() const { ASSERT(this); return m_szHost; } ///< ホスト側の名称を取得
|
const TCHAR* GetHost() const { return m_szHost; } ///< ホスト側の名称を取得
|
||||||
void ConvertHuman(int nCount = -1); ///< Human68k側の名称を変換
|
void ConvertHuman(int nCount = -1); ///< Human68k側の名称を変換
|
||||||
void CopyHuman(const BYTE* szHuman); ///< Human68k側の名称を複製
|
void CopyHuman(const BYTE* szHuman); ///< Human68k側の名称を複製
|
||||||
BOOL isReduce() const; ///< Human68k側の名称が加工されたか調査
|
BOOL isReduce() const; ///< Human68k側の名称が加工されたか調査
|
||||||
BOOL isCorrect() const { ASSERT(this); return m_bCorrect; } ///< Human68k側のファイル名規則に合致しているか調査
|
BOOL isCorrect() const { return m_bCorrect; } ///< Human68k側のファイル名規則に合致しているか調査
|
||||||
const BYTE* GetHuman() const { ASSERT(this); return m_szHuman; } ///< Human68kファイル名を取得
|
const BYTE* GetHuman() const { return m_szHuman; } ///< Human68kファイル名を取得
|
||||||
const BYTE* GetHumanLast() const
|
const BYTE* GetHumanLast() const
|
||||||
{ ASSERT(this); return m_pszHumanLast; } ///< Human68kファイル名を取得
|
{ return m_pszHumanLast; } ///< Human68kファイル名を取得
|
||||||
const BYTE* GetHumanExt() const { ASSERT(this); return m_pszHumanExt; }///< Human68kファイル名を取得
|
const BYTE* GetHumanExt() const { return m_pszHumanExt; }///< Human68kファイル名を取得
|
||||||
void SetEntryName(); ///< Human68kディレクトリエントリを設定
|
void SetEntryName(); ///< Human68kディレクトリエントリを設定
|
||||||
void SetEntryAttribute(BYTE nHumanAttribute)
|
void SetEntryAttribute(BYTE nHumanAttribute)
|
||||||
{ ASSERT(this); m_dirHuman.attr = nHumanAttribute; } ///< Human68kディレクトリエントリを設定
|
{ m_dirHuman.attr = nHumanAttribute; } ///< Human68kディレクトリエントリを設定
|
||||||
void SetEntrySize(DWORD nHumanSize)
|
void SetEntrySize(DWORD nHumanSize)
|
||||||
{ ASSERT(this); m_dirHuman.size = nHumanSize; } ///< Human68kディレクトリエントリを設定
|
{ m_dirHuman.size = nHumanSize; } ///< Human68kディレクトリエントリを設定
|
||||||
void SetEntryDate(WORD nHumanDate)
|
void SetEntryDate(WORD nHumanDate)
|
||||||
{ ASSERT(this); m_dirHuman.date = nHumanDate; } ///< Human68kディレクトリエントリを設定
|
{ m_dirHuman.date = nHumanDate; } ///< Human68kディレクトリエントリを設定
|
||||||
void SetEntryTime(WORD nHumanTime)
|
void SetEntryTime(WORD nHumanTime)
|
||||||
{ ASSERT(this); m_dirHuman.time = nHumanTime; } ///< Human68kディレクトリエントリを設定
|
{ m_dirHuman.time = nHumanTime; } ///< Human68kディレクトリエントリを設定
|
||||||
void SetEntryCluster(WORD nHumanCluster)
|
void SetEntryCluster(WORD nHumanCluster)
|
||||||
{ ASSERT(this); m_dirHuman.cluster = nHumanCluster; } ///< Human68kディレクトリエントリを設定
|
{ m_dirHuman.cluster = nHumanCluster; } ///< Human68kディレクトリエントリを設定
|
||||||
const Human68k::dirent_t* GetEntry() const
|
const Human68k::dirent_t* GetEntry() const
|
||||||
{ ASSERT(this); return &m_dirHuman; } ///< Human68kディレクトリエントリを取得
|
{ return &m_dirHuman; } ///< Human68kディレクトリエントリを取得
|
||||||
BOOL CheckAttribute(DWORD nHumanAttribute) const; ///< Human68kディレクトリエントリの属性判定
|
BOOL CheckAttribute(DWORD nHumanAttribute) const; ///< Human68kディレクトリエントリの属性判定
|
||||||
BOOL isSameEntry(const Human68k::dirent_t* pdirHuman) const
|
BOOL isSameEntry(const Human68k::dirent_t* pdirHuman) const
|
||||||
{ ASSERT(this); ASSERT(pdirHuman); return memcmp(&m_dirHuman, pdirHuman, sizeof(m_dirHuman)) == 0; }
|
{ ASSERT(pdirHuman); return memcmp(&m_dirHuman, pdirHuman, sizeof(m_dirHuman)) == 0; }
|
||||||
///< Human68kディレクトリエントリの一致判定
|
///< Human68kディレクトリエントリの一致判定
|
||||||
|
|
||||||
// パス名操作
|
// パス名操作
|
||||||
@ -555,7 +551,7 @@ public:
|
|||||||
void SetHost(const TCHAR* szHost); ///< ホスト側の名称を直接指定する
|
void SetHost(const TCHAR* szHost); ///< ホスト側の名称を直接指定する
|
||||||
BOOL isSameHuman(const BYTE* szHuman) const; ///< Human68k側の名称を比較する
|
BOOL isSameHuman(const BYTE* szHuman) const; ///< Human68k側の名称を比較する
|
||||||
BOOL isSameChild(const BYTE* szHuman) const; ///< Human68k側の名称を比較する
|
BOOL isSameChild(const BYTE* szHuman) const; ///< Human68k側の名称を比較する
|
||||||
const TCHAR* GetHost() const { ASSERT(this); return m_szHost; } ///< ホスト側の名称の獲得
|
const TCHAR* GetHost() const { return m_szHost; } ///< ホスト側の名称の獲得
|
||||||
const CHostFilename* FindFilename(const BYTE* szHuman, DWORD nHumanAttribute = Human68k::AT_ALL) const;
|
const CHostFilename* FindFilename(const BYTE* szHuman, DWORD nHumanAttribute = Human68k::AT_ALL) const;
|
||||||
///< ファイル名を検索
|
///< ファイル名を検索
|
||||||
const CHostFilename* FindFilenameWildcard(const BYTE* szHuman, DWORD nHumanAttribute, find_t* pFind) const;
|
const CHostFilename* FindFilenameWildcard(const BYTE* szHuman, DWORD nHumanAttribute, find_t* pFind) const;
|
||||||
@ -617,8 +613,8 @@ public:
|
|||||||
CHostFiles() { SetKey(0); Init(); } ///< デフォルトコンストラクタ
|
CHostFiles() { SetKey(0); Init(); } ///< デフォルトコンストラクタ
|
||||||
void Init(); ///< 初期化
|
void Init(); ///< 初期化
|
||||||
|
|
||||||
void SetKey(DWORD nKey) { ASSERT(this); m_nKey = nKey; } ///< 検索キー設定
|
void SetKey(DWORD nKey) { m_nKey = nKey; } ///< 検索キー設定
|
||||||
BOOL isSameKey(DWORD nKey) const { ASSERT(this); return m_nKey == nKey; } ///< 検索キー比較
|
BOOL isSameKey(DWORD nKey) const { return m_nKey == nKey; } ///< 検索キー比較
|
||||||
void SetPath(const Human68k::namests_t* pNamests); ///< パス名・ファイル名を内部で生成
|
void SetPath(const Human68k::namests_t* pNamests); ///< パス名・ファイル名を内部で生成
|
||||||
BOOL isRootPath() const { return m_szHumanPath[1] == '\0'; } ///< ルートディレクトリ判定
|
BOOL isRootPath() const { return m_szHumanPath[1] == '\0'; } ///< ルートディレクトリ判定
|
||||||
void SetPathWildcard() { m_nHumanWildcard = 1; } ///< ワイルドカードによるファイル検索を有効化
|
void SetPathWildcard() { m_nHumanWildcard = 1; } ///< ワイルドカードによるファイル検索を有効化
|
||||||
@ -633,17 +629,17 @@ public:
|
|||||||
void AddResult(const TCHAR* szPath); ///< ホスト側の名称にファイル名を追加
|
void AddResult(const TCHAR* szPath); ///< ホスト側の名称にファイル名を追加
|
||||||
void AddFilename(); ///< ホスト側の名称にHuman68kの新規ファイル名を追加
|
void AddFilename(); ///< ホスト側の名称にHuman68kの新規ファイル名を追加
|
||||||
|
|
||||||
const TCHAR* GetPath() const { ASSERT(this); return m_szHostResult; } ///< ホスト側の名称を取得
|
const TCHAR* GetPath() const { return m_szHostResult; } ///< ホスト側の名称を取得
|
||||||
|
|
||||||
const Human68k::dirent_t* GetEntry() const { ASSERT(this); return &m_dirHuman; }///< Human68kディレクトリエントリを取得
|
const Human68k::dirent_t* GetEntry() const { return &m_dirHuman; }///< Human68kディレクトリエントリを取得
|
||||||
|
|
||||||
DWORD GetAttribute() const { ASSERT(this); return m_dirHuman.attr; } ///< Human68k属性を取得
|
DWORD GetAttribute() const { return m_dirHuman.attr; } ///< Human68k属性を取得
|
||||||
WORD GetDate() const { ASSERT(this); return m_dirHuman.date; } ///< Human68k日付を取得
|
WORD GetDate() const { return m_dirHuman.date; } ///< Human68k日付を取得
|
||||||
WORD GetTime() const { ASSERT(this); return m_dirHuman.time; } ///< Human68k時刻を取得
|
WORD GetTime() const { return m_dirHuman.time; } ///< Human68k時刻を取得
|
||||||
DWORD GetSize() const { ASSERT(this); return m_dirHuman.size; } ///< Human68kファイルサイズを取得
|
DWORD GetSize() const { return m_dirHuman.size; } ///< Human68kファイルサイズを取得
|
||||||
const BYTE* GetHumanFilename() const { ASSERT(this); return m_szHumanFilename; }///< Human68kファイル名を取得
|
const BYTE* GetHumanFilename() const { return m_szHumanFilename; }///< Human68kファイル名を取得
|
||||||
const BYTE* GetHumanResult() const { ASSERT(this); return m_szHumanResult; } ///< Human68kファイル名検索結果を取得
|
const BYTE* GetHumanResult() const { return m_szHumanResult; } ///< Human68kファイル名検索結果を取得
|
||||||
const BYTE* GetHumanPath() const { ASSERT(this); return m_szHumanPath; } ///< Human68kパス名を取得
|
const BYTE* GetHumanPath() const { return m_szHumanPath; } ///< Human68kパス名を取得
|
||||||
|
|
||||||
private:
|
private:
|
||||||
DWORD m_nKey; ///< Human68kのFILESバッファアドレス 0なら未使用
|
DWORD m_nKey; ///< Human68kのFILESバッファアドレス 0なら未使用
|
||||||
@ -697,14 +693,14 @@ public:
|
|||||||
~CHostFcb() { Close(); } ///< デストラクタ final
|
~CHostFcb() { Close(); } ///< デストラクタ final
|
||||||
void Init(); ///< 初期化
|
void Init(); ///< 初期化
|
||||||
|
|
||||||
void SetKey(DWORD nKey) { ASSERT(this); m_nKey = nKey; } ///< 検索キー設定
|
void SetKey(DWORD nKey) { m_nKey = nKey; } ///< 検索キー設定
|
||||||
BOOL isSameKey(DWORD nKey) const { ASSERT(this); return m_nKey == nKey; } ///< 検索キー比較
|
BOOL isSameKey(DWORD nKey) const { return m_nKey == nKey; } ///< 検索キー比較
|
||||||
void SetUpdate() { ASSERT(this); m_bUpdate = TRUE; } ///< 更新
|
void SetUpdate() { m_bUpdate = TRUE; } ///< 更新
|
||||||
BOOL isUpdate() const { ASSERT(this); return m_bUpdate; } ///< 更新状態取得
|
BOOL isUpdate() const { return m_bUpdate; } ///< 更新状態取得
|
||||||
BOOL SetMode(DWORD nHumanMode); ///< ファイルオープンモードを設定
|
BOOL SetMode(DWORD nHumanMode); ///< ファイルオープンモードを設定
|
||||||
void SetFilename(const TCHAR* szFilename); ///< ファイル名を設定
|
void SetFilename(const TCHAR* szFilename); ///< ファイル名を設定
|
||||||
void SetHumanPath(const BYTE* szHumanPath); ///< Human68kパス名を設定
|
void SetHumanPath(const BYTE* szHumanPath); ///< Human68kパス名を設定
|
||||||
const BYTE* GetHumanPath() const { ASSERT(this); return m_szHumanPath; } ///< Human68kパス名を取得
|
const BYTE* GetHumanPath() const { return m_szHumanPath; } ///< Human68kパス名を取得
|
||||||
|
|
||||||
BOOL Create(Human68k::fcb_t* pFcb, DWORD nHumanAttribute, BOOL bForce); ///< ファイル作成
|
BOOL Create(Human68k::fcb_t* pFcb, DWORD nHumanAttribute, BOOL bForce); ///< ファイル作成
|
||||||
BOOL Open(); ///< ファイルオープン
|
BOOL Open(); ///< ファイルオープン
|
||||||
@ -775,8 +771,8 @@ public:
|
|||||||
~CHostDrv(); ///< デストラクタ final
|
~CHostDrv(); ///< デストラクタ final
|
||||||
void Init(const TCHAR* szBase, DWORD nFlag); ///< 初期化 (デバイス起動とロード)
|
void Init(const TCHAR* szBase, DWORD nFlag); ///< 初期化 (デバイス起動とロード)
|
||||||
|
|
||||||
BOOL isWriteProtect() const { ASSERT(this); return m_bWriteProtect; } ///< 書き込み禁止か?
|
BOOL isWriteProtect() const { return m_bWriteProtect; } ///< 書き込み禁止か?
|
||||||
BOOL isEnable() const { ASSERT(this); return m_bEnable; } ///< アクセス可能か?
|
BOOL isEnable() const { return m_bEnable; } ///< アクセス可能か?
|
||||||
BOOL isMediaOffline(); ///< メディアチェック
|
BOOL isMediaOffline(); ///< メディアチェック
|
||||||
BYTE GetMediaByte() const; ///< メディアバイトの取得
|
BYTE GetMediaByte() const; ///< メディアバイトの取得
|
||||||
DWORD GetStatus() const; ///< ドライブ状態の取得
|
DWORD GetStatus() const; ///< ドライブ状態の取得
|
||||||
@ -950,11 +946,11 @@ public:
|
|||||||
int Lock(DWORD nUnit); ///< $58 - 排他制御
|
int Lock(DWORD nUnit); ///< $58 - 排他制御
|
||||||
|
|
||||||
void SetOption(DWORD nOption); ///< オプション設定
|
void SetOption(DWORD nOption); ///< オプション設定
|
||||||
DWORD GetOption() const { ASSERT(this); return m_nOption; } ///< オプション取得
|
DWORD GetOption() const { return m_nOption; } ///< オプション取得
|
||||||
DWORD GetDefault() const { ASSERT(this); return m_nOptionDefault; } ///< デフォルトオプション取得
|
DWORD GetDefault() const { return m_nOptionDefault; } ///< デフォルトオプション取得
|
||||||
static DWORD GetFileOption() { return g_nOption; } ///< ファイル名変換オプション取得
|
static DWORD GetFileOption() { return g_nOption; } ///< ファイル名変換オプション取得
|
||||||
void ShellNotify(DWORD nEvent, const TCHAR* szPath)
|
void ShellNotify(DWORD nEvent, const TCHAR* szPath)
|
||||||
{ ASSERT(this); m_cEntry.ShellNotify(nEvent, szPath); } ///< ホスト側ファイルシステム状態変化通知
|
{ m_cEntry.ShellNotify(nEvent, szPath); } ///< ホスト側ファイルシステム状態変化通知
|
||||||
|
|
||||||
/// 定数
|
/// 定数
|
||||||
enum {
|
enum {
|
||||||
|
@ -124,7 +124,6 @@ int FASTCALL SCSIDaynaPort::Inquiry(
|
|||||||
// scsi_cdb_6_byte_t command;
|
// scsi_cdb_6_byte_t command;
|
||||||
// memcpy(&command,cdb,sizeof(command));
|
// memcpy(&command,cdb,sizeof(command));
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(cdb);
|
ASSERT(cdb);
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(cdb[0] == 0x12);
|
ASSERT(cdb[0] == 0x12);
|
||||||
@ -200,7 +199,6 @@ int FASTCALL SCSIDaynaPort::Read(const DWORD *cdb, BYTE *buf, DWORD block)
|
|||||||
scsi_cmd_read_6_t *command = (scsi_cmd_read_6_t*)cdb;
|
scsi_cmd_read_6_t *command = (scsi_cmd_read_6_t*)cdb;
|
||||||
int read_count = 0;
|
int read_count = 0;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buf);
|
ASSERT(buf);
|
||||||
|
|
||||||
LOGTRACE("%s reading DaynaPort block %lu", __PRETTY_FUNCTION__, block);
|
LOGTRACE("%s reading DaynaPort block %lu", __PRETTY_FUNCTION__, block);
|
||||||
@ -408,7 +406,6 @@ int FASTCALL SCSIDaynaPort::RetrieveStats(const DWORD *cdb, BYTE *buffer)
|
|||||||
|
|
||||||
LOGTRACE("%s RetrieveStats ", __PRETTY_FUNCTION__);
|
LOGTRACE("%s RetrieveStats ", __PRETTY_FUNCTION__);
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(cdb);
|
ASSERT(cdb);
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
|
|
||||||
@ -522,7 +519,6 @@ BOOL FASTCALL SCSIDaynaPort::EnableInterface(const DWORD *cdb)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL SCSIDaynaPort::TestUnitReady(const DWORD* /*cdb*/)
|
BOOL FASTCALL SCSIDaynaPort::TestUnitReady(const DWORD* /*cdb*/)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
LOGTRACE("%s", __PRETTY_FUNCTION__);
|
LOGTRACE("%s", __PRETTY_FUNCTION__);
|
||||||
|
|
||||||
// TEST UNIT READY Success
|
// TEST UNIT READY Success
|
||||||
@ -541,7 +537,7 @@ void FASTCALL SCSIDaynaPort::SetMode(const DWORD *cdb, BYTE *buffer)
|
|||||||
|
|
||||||
for(size_t i=0; i<sizeof(6); i++)
|
for(size_t i=0; i<sizeof(6); i++)
|
||||||
{
|
{
|
||||||
LOGTRACE("%s %d: %02X",__PRETTY_FUNCTION__, i,(WORD)cdb[i]);
|
LOGTRACE("%s %d: %02X",__PRETTY_FUNCTION__, (unsigned int)i,(WORD)cdb[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -51,7 +51,6 @@ Fileio::~Fileio()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Load(const Filepath& path, void *buffer, int size)
|
BOOL FASTCALL Fileio::Load(const Filepath& path, void *buffer, int size)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(handle < 0);
|
ASSERT(handle < 0);
|
||||||
@ -80,7 +79,6 @@ BOOL FASTCALL Fileio::Load(const Filepath& path, void *buffer, int size)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Save(const Filepath& path, void *buffer, int size)
|
BOOL FASTCALL Fileio::Save(const Filepath& path, void *buffer, int size)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(handle < 0);
|
ASSERT(handle < 0);
|
||||||
@ -111,7 +109,6 @@ BOOL FASTCALL Fileio::Open(LPCTSTR fname, OpenMode mode, BOOL directIO)
|
|||||||
{
|
{
|
||||||
mode_t omode;
|
mode_t omode;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(fname);
|
ASSERT(fname);
|
||||||
ASSERT(handle < 0);
|
ASSERT(handle < 0);
|
||||||
|
|
||||||
@ -172,7 +169,6 @@ BOOL FASTCALL Fileio::Open(LPCTSTR fname, OpenMode mode, BOOL directIO)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Open(LPCTSTR fname, OpenMode mode)
|
BOOL FASTCALL Fileio::Open(LPCTSTR fname, OpenMode mode)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
return Open(fname, mode, FALSE);
|
return Open(fname, mode, FALSE);
|
||||||
}
|
}
|
||||||
@ -184,7 +180,6 @@ BOOL FASTCALL Fileio::Open(LPCTSTR fname, OpenMode mode)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Open(const Filepath& path, OpenMode mode)
|
BOOL FASTCALL Fileio::Open(const Filepath& path, OpenMode mode)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
return Open(path.GetPath(), mode);
|
return Open(path.GetPath(), mode);
|
||||||
}
|
}
|
||||||
@ -196,7 +191,6 @@ BOOL FASTCALL Fileio::Open(const Filepath& path, OpenMode mode)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::OpenDIO(LPCTSTR fname, OpenMode mode)
|
BOOL FASTCALL Fileio::OpenDIO(LPCTSTR fname, OpenMode mode)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// O_DIRECT付きでオープン
|
// O_DIRECT付きでオープン
|
||||||
if (!Open(fname, mode, TRUE)) {
|
if (!Open(fname, mode, TRUE)) {
|
||||||
@ -214,7 +208,6 @@ BOOL FASTCALL Fileio::OpenDIO(LPCTSTR fname, OpenMode mode)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::OpenDIO(const Filepath& path, OpenMode mode)
|
BOOL FASTCALL Fileio::OpenDIO(const Filepath& path, OpenMode mode)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
return OpenDIO(path.GetPath(), mode);
|
return OpenDIO(path.GetPath(), mode);
|
||||||
}
|
}
|
||||||
@ -228,7 +221,6 @@ BOOL FASTCALL Fileio::Read(void *buffer, int size)
|
|||||||
{
|
{
|
||||||
int count;
|
int count;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(handle >= 0);
|
ASSERT(handle >= 0);
|
||||||
@ -251,7 +243,6 @@ BOOL FASTCALL Fileio::Write(const void *buffer, int size)
|
|||||||
{
|
{
|
||||||
int count;
|
int count;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(handle >= 0);
|
ASSERT(handle >= 0);
|
||||||
@ -272,7 +263,6 @@ BOOL FASTCALL Fileio::Write(const void *buffer, int size)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Seek(off64_t offset, BOOL relative)
|
BOOL FASTCALL Fileio::Seek(off64_t offset, BOOL relative)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(handle >= 0);
|
ASSERT(handle >= 0);
|
||||||
ASSERT(offset >= 0);
|
ASSERT(offset >= 0);
|
||||||
|
|
||||||
@ -298,7 +288,6 @@ off64_t FASTCALL Fileio::GetFileSize()
|
|||||||
off64_t cur;
|
off64_t cur;
|
||||||
off64_t end;
|
off64_t end;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(handle >= 0);
|
ASSERT(handle >= 0);
|
||||||
|
|
||||||
// ファイル位置を64bitで取得
|
// ファイル位置を64bitで取得
|
||||||
@ -322,7 +311,6 @@ off64_t FASTCALL Fileio::GetFilePos() const
|
|||||||
{
|
{
|
||||||
off64_t pos;
|
off64_t pos;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(handle >= 0);
|
ASSERT(handle >= 0);
|
||||||
|
|
||||||
// ファイル位置を64bitで取得
|
// ファイル位置を64bitで取得
|
||||||
@ -338,7 +326,6 @@ off64_t FASTCALL Fileio::GetFilePos() const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void FASTCALL Fileio::Close()
|
void FASTCALL Fileio::Close()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
if (handle != -1) {
|
if (handle != -1) {
|
||||||
close(handle);
|
close(handle);
|
||||||
@ -377,7 +364,6 @@ Fileio::~Fileio()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Load(const Filepath& path, void *buffer, int size)
|
BOOL FASTCALL Fileio::Load(const Filepath& path, void *buffer, int size)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(!handle.obj.fs);
|
ASSERT(!handle.obj.fs);
|
||||||
@ -406,7 +392,6 @@ BOOL FASTCALL Fileio::Load(const Filepath& path, void *buffer, int size)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Save(const Filepath& path, void *buffer, int size)
|
BOOL FASTCALL Fileio::Save(const Filepath& path, void *buffer, int size)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(!handle.obj.fs);
|
ASSERT(!handle.obj.fs);
|
||||||
@ -437,7 +422,6 @@ BOOL FASTCALL Fileio::Open(LPCTSTR fname, OpenMode mode)
|
|||||||
{
|
{
|
||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
Filepath fpath;
|
Filepath fpath;
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(fname);
|
ASSERT(fname);
|
||||||
ASSERT(!handle.obj.fs);
|
ASSERT(!handle.obj.fs);
|
||||||
|
|
||||||
@ -491,7 +475,6 @@ BOOL FASTCALL Fileio::Open(LPCTSTR fname, OpenMode mode)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Fileio::Open(const Filepath& path, OpenMode mode)
|
BOOL FASTCALL Fileio::Open(const Filepath& path, OpenMode mode)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(!handle.obj.fs);
|
ASSERT(!handle.obj.fs);
|
||||||
|
|
||||||
return Open(path.GetPath(), mode);
|
return Open(path.GetPath(), mode);
|
||||||
@ -507,7 +490,6 @@ BOOL FASTCALL Fileio::Read(void *buffer, int size)
|
|||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
UINT count;
|
UINT count;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(handle.obj.fs);
|
ASSERT(handle.obj.fs);
|
||||||
@ -531,7 +513,6 @@ BOOL FASTCALL Fileio::Write(const void *buffer, int size)
|
|||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
UINT count;
|
UINT count;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(buffer);
|
ASSERT(buffer);
|
||||||
ASSERT(size > 0);
|
ASSERT(size > 0);
|
||||||
ASSERT(handle.obj.fs);
|
ASSERT(handle.obj.fs);
|
||||||
@ -554,7 +535,6 @@ BOOL FASTCALL Fileio::Seek(off64_t offset, BOOL relative)
|
|||||||
{
|
{
|
||||||
FRESULT fr;
|
FRESULT fr;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(offset >= 0);
|
ASSERT(offset >= 0);
|
||||||
ASSERT(handle.obj.fs);
|
ASSERT(handle.obj.fs);
|
||||||
|
|
||||||
@ -582,7 +562,6 @@ BOOL FASTCALL Fileio::Seek(off64_t offset, BOOL relative)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
off64_t FASTCALL Fileio::GetFileSize()
|
off64_t FASTCALL Fileio::GetFileSize()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(handle.obj.fs);
|
ASSERT(handle.obj.fs);
|
||||||
|
|
||||||
return f_size(&handle);
|
return f_size(&handle);
|
||||||
@ -595,7 +574,6 @@ off64_t FASTCALL Fileio::GetFileSize()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
off64_t FASTCALL Fileio::GetFilePos() const
|
off64_t FASTCALL Fileio::GetFilePos() const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(handle.obj.fs);
|
ASSERT(handle.obj.fs);
|
||||||
|
|
||||||
return f_tell(&handle);
|
return f_tell(&handle);
|
||||||
@ -608,7 +586,6 @@ off64_t FASTCALL Fileio::GetFilePos() const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void FASTCALL Fileio::Close()
|
void FASTCALL Fileio::Close()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
if (handle.obj.fs) {
|
if (handle.obj.fs) {
|
||||||
f_close(&handle);
|
f_close(&handle);
|
||||||
|
@ -59,7 +59,6 @@ Filepath& Filepath::operator=(const Filepath& path)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void FASTCALL Filepath::Clear()
|
void FASTCALL Filepath::Clear()
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// Clear the path and each part
|
// Clear the path and each part
|
||||||
m_szPath[0] = _T('\0');
|
m_szPath[0] = _T('\0');
|
||||||
@ -75,7 +74,6 @@ void FASTCALL Filepath::Clear()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void FASTCALL Filepath::SetPath(LPCSTR path)
|
void FASTCALL Filepath::SetPath(LPCSTR path)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(path);
|
ASSERT(path);
|
||||||
ASSERT(strlen(path) < _MAX_PATH);
|
ASSERT(strlen(path) < _MAX_PATH);
|
||||||
|
|
||||||
@ -173,7 +171,6 @@ void FASTCALL Filepath::Split()
|
|||||||
LPTSTR pBaseName;
|
LPTSTR pBaseName;
|
||||||
LPTSTR pExtName;
|
LPTSTR pExtName;
|
||||||
|
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// パーツを初期化
|
// パーツを初期化
|
||||||
m_szDir[0] = _T('\0');
|
m_szDir[0] = _T('\0');
|
||||||
@ -214,7 +211,6 @@ void FASTCALL Filepath::Split()
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
LPCTSTR FASTCALL Filepath::GetFileExt() const
|
LPCTSTR FASTCALL Filepath::GetFileExt() const
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
|
|
||||||
// 固定バッファへ合成
|
// 固定バッファへ合成
|
||||||
strcpy(FileExt, m_szExt);
|
strcpy(FileExt, m_szExt);
|
||||||
@ -230,7 +226,6 @@ LPCTSTR FASTCALL Filepath::GetFileExt() const
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Filepath::Save(Fileio *fio, int /*ver*/)
|
BOOL FASTCALL Filepath::Save(Fileio *fio, int /*ver*/)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(fio);
|
ASSERT(fio);
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -243,7 +238,6 @@ BOOL FASTCALL Filepath::Save(Fileio *fio, int /*ver*/)
|
|||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
BOOL FASTCALL Filepath::Load(Fileio *fio, int /*ver*/)
|
BOOL FASTCALL Filepath::Load(Fileio *fio, int /*ver*/)
|
||||||
{
|
{
|
||||||
ASSERT(this);
|
|
||||||
ASSERT(fio);
|
ASSERT(fio);
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
@ -43,7 +43,10 @@ public:
|
|||||||
reserved // 未使用/リザーブ
|
reserved // 未使用/リザーブ
|
||||||
};
|
};
|
||||||
|
|
||||||
// Basic Functions
|
BUS() { };
|
||||||
|
virtual ~BUS() { };
|
||||||
|
|
||||||
|
// Basic Functions
|
||||||
// 基本ファンクション
|
// 基本ファンクション
|
||||||
virtual BOOL FASTCALL Init(mode_e mode) = 0;
|
virtual BOOL FASTCALL Init(mode_e mode) = 0;
|
||||||
// 初期化
|
// 初期化
|
||||||
|
Loading…
Reference in New Issue
Block a user