[Scummvm-git-logs] scummvm master -> 1994249ef230c7bc4644d988535b882d7936665b

AReim1982 alexander at areim.de
Thu Oct 1 11:04:46 UTC 2020


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
1994249ef2 WII: Add support for WiiFilesystemNode::createDirectory()


Commit: 1994249ef230c7bc4644d988535b882d7936665b
    https://github.com/scummvm/scummvm/commit/1994249ef230c7bc4644d988535b882d7936665b
Author: Alexander Reim (alexander at areim.de)
Date: 2020-10-01T13:03:52+02:00

Commit Message:
WII: Add support for WiiFilesystemNode::createDirectory()

Changed paths:
    backends/fs/wii/wii-fs.cpp


diff --git a/backends/fs/wii/wii-fs.cpp b/backends/fs/wii/wii-fs.cpp
index eb0beed166..7a7de18809 100644
--- a/backends/fs/wii/wii-fs.cpp
+++ b/backends/fs/wii/wii-fs.cpp
@@ -165,7 +165,7 @@ bool WiiFilesystemNode::getChildren(AbstractFSList &list, ListMode mode, bool hi
 
 		Common::String newPath(_path);
 		if (newPath.lastChar() != '/')
-		  newPath += '/';
+			newPath += '/';
 		newPath += pent->d_name;
 
 		bool isDir = ( pent->d_type == DT_DIR );
@@ -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;
 }
 




More information about the Scummvm-git-logs mailing list