fs: implement DeleteDirectoryRecursively
This commit is contained in:
parent
4b14e17b18
commit
96b0e9476b
8 changed files with 70 additions and 1 deletions
|
@ -362,6 +362,18 @@ ResultCode DeleteDirectoryFromArchive(ArchiveHandle archive_handle, const FileSy
|
|||
ErrorSummary::Canceled, ErrorLevel::Status);
|
||||
}
|
||||
|
||||
ResultCode DeleteDirectoryRecursivelyFromArchive(ArchiveHandle archive_handle,
|
||||
const FileSys::Path& path) {
|
||||
ArchiveBackend* archive = GetArchive(archive_handle);
|
||||
if (archive == nullptr)
|
||||
return ERR_INVALID_ARCHIVE_HANDLE;
|
||||
|
||||
if (archive->DeleteDirectoryRecursively(path))
|
||||
return RESULT_SUCCESS;
|
||||
return ResultCode(ErrorDescription::NoData, ErrorModule::FS, // TODO: verify description
|
||||
ErrorSummary::Canceled, ErrorLevel::Status);
|
||||
}
|
||||
|
||||
ResultCode CreateFileInArchive(ArchiveHandle archive_handle, const FileSys::Path& path,
|
||||
u64 file_size) {
|
||||
ArchiveBackend* archive = GetArchive(archive_handle);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue