Use OF_READ

This commit is contained in:
Christian Semmler 2024-12-16 14:02:58 -07:00
parent eacebb681e
commit 84b31ae6d0
2 changed files with 4 additions and 4 deletions

View file

@ -92,11 +92,11 @@ MxResult MxDiskStreamProvider::SetResourceToGet(MxStreamController* p_resource)
m_pFile = new MxDSFile(path.GetData(), 0); m_pFile = new MxDSFile(path.GetData(), 0);
if (m_pFile != NULL) { if (m_pFile != NULL) {
if (m_pFile->Open(0) != 0) { if (m_pFile->Open(OF_READ) != 0) {
path = MxString(MxOmni::GetCD()) + p_resource->GetAtom().GetInternal() + ".si"; path = MxString(MxOmni::GetCD()) + p_resource->GetAtom().GetInternal() + ".si";
m_pFile->SetFileName(path.GetData()); m_pFile->SetFileName(path.GetData());
if (m_pFile->Open(0) != 0) { if (m_pFile->Open(OF_READ) != 0) {
goto done; goto done;
} }
} }

View file

@ -68,11 +68,11 @@ MxResult MxRAMStreamProvider::SetResourceToGet(MxStreamController* p_resource)
m_pFile = new MxDSFile(path.GetData(), 0); m_pFile = new MxDSFile(path.GetData(), 0);
if (m_pFile != NULL) { if (m_pFile != NULL) {
if (m_pFile->Open(0) != 0) { if (m_pFile->Open(OF_READ) != 0) {
path = MxString(MxOmni::GetCD()) + p_resource->GetAtom().GetInternal() + ".si"; path = MxString(MxOmni::GetCD()) + p_resource->GetAtom().GetInternal() + ".si";
m_pFile->SetFileName(path.GetData()); m_pFile->SetFileName(path.GetData());
if (m_pFile->Open(0) != 0) { if (m_pFile->Open(OF_READ) != 0) {
goto done; goto done;
} }
} }