mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-12 12:09:15 +00:00
COMMON: Access mac res fork via FSNode instead of StdioStream
This fixes linker problems with the unit tests on Mac OS X. it is also "more proper" to use the high-level FSNode API. StdioStream is a (relatively) low-level wrapper intended for use inside of backends only.
This commit is contained in:
parent
11bd6da595
commit
3cc2e5b927
@ -32,7 +32,6 @@
|
||||
|
||||
#ifdef MACOSX
|
||||
#include "common/config-manager.h"
|
||||
#include "backends/fs/stdiostream.h"
|
||||
#endif
|
||||
|
||||
namespace Common {
|
||||
@ -108,7 +107,7 @@ bool MacResManager::open(String filename) {
|
||||
#ifdef MACOSX
|
||||
// Check the actual fork on a Mac computer
|
||||
String fullPath = ConfMan.get("path") + "/" + filename + "/..namedfork/rsrc";
|
||||
SeekableReadStream *macResForkRawStream = StdioStream::makeFromPath(fullPath, false);
|
||||
SeekableReadStream *macResForkRawStream = FSNode(fullPath).createReadStream();;
|
||||
|
||||
if (macResForkRawStream && loadFromRawFork(*macResForkRawStream)) {
|
||||
_baseFileName = filename;
|
||||
@ -168,7 +167,7 @@ bool MacResManager::open(FSNode path, String filename) {
|
||||
#ifdef MACOSX
|
||||
// Check the actual fork on a Mac computer
|
||||
String fullPath = path.getPath() + "/" + filename + "/..namedfork/rsrc";
|
||||
SeekableReadStream *macResForkRawStream = StdioStream::makeFromPath(fullPath, false);
|
||||
SeekableReadStream *macResForkRawStream = FSNode(fullPath).createReadStream();
|
||||
|
||||
if (macResForkRawStream && loadFromRawFork(*macResForkRawStream)) {
|
||||
_baseFileName = filename;
|
||||
|
Loading…
Reference in New Issue
Block a user