WII: Add support for WiiFilesystemNode::createDirectory()

This commit is contained in:
Alexander Reim 2020-10-01 13:03:52 +02:00
parent 89d07e7084
commit 1994249ef2

View File

@ -221,7 +221,15 @@ Common::WriteStream *WiiFilesystemNode::createWriteStream() {
}
bool WiiFilesystemNode::createDirectory() {
warning("WiiFilesystemNode::createDirectory(): Not supported");
if(!_exists) {
if (mkdir(_path.c_str(), 0755) == 0) {
_exists = true;
_isDirectory = true;
_isReadable = true;
_isWritable = true;
}
}
return _exists && _isDirectory;
}