mirror of
https://github.com/Atmosphere-NX/Atmosphere
synced 2024-11-15 01:26:34 +00:00
Fixed placeholder/content deletion
This commit is contained in:
parent
ef28b7d395
commit
9e9987a673
2 changed files with 14 additions and 14 deletions
|
@ -80,13 +80,13 @@ namespace sts::ncm::impl {
|
||||||
|
|
||||||
this->GetPlaceHolderPathUncached(placeholder_path, placeholder_id);
|
this->GetPlaceHolderPathUncached(placeholder_path, placeholder_id);
|
||||||
|
|
||||||
debug::DebugLog("Deleting %s\n", placeholder_path);
|
if (std::remove(placeholder_path) != 0) {
|
||||||
|
R_TRY_CATCH(fsdevGetLastResult()) {
|
||||||
R_TRY_CATCH(fsdevDeleteDirectoryRecursively(placeholder_path)) {
|
R_CATCH(ResultFsPathNotFound) {
|
||||||
R_CATCH(ResultFsPathNotFound) {
|
return ResultNcmPlaceHolderNotFound;
|
||||||
return ResultNcmPlaceHolderNotFound;
|
}
|
||||||
}
|
} R_END_TRY_CATCH;
|
||||||
} R_END_TRY_CATCH;
|
}
|
||||||
|
|
||||||
return ResultSuccess;
|
return ResultSuccess;
|
||||||
}
|
}
|
||||||
|
|
|
@ -223,16 +223,16 @@ namespace sts::ncm {
|
||||||
}
|
}
|
||||||
|
|
||||||
this->ClearContentCache();
|
this->ClearContentCache();
|
||||||
|
|
||||||
char content_path[FS_MAX_PATH] = {0};
|
char content_path[FS_MAX_PATH] = {0};
|
||||||
|
|
||||||
this->GetContentPath(content_path, content_id);
|
this->GetContentPath(content_path, content_id);
|
||||||
|
|
||||||
R_TRY_CATCH(fsdevDeleteDirectoryRecursively(content_path)) {
|
if (std::remove(content_path) != 0) {
|
||||||
R_CATCH(ResultFsPathNotFound) {
|
R_TRY_CATCH(fsdevGetLastResult()) {
|
||||||
return ResultNcmContentNotFound;
|
R_CATCH(ResultFsPathNotFound) {
|
||||||
}
|
return ResultNcmContentNotFound;
|
||||||
} R_END_TRY_CATCH;
|
}
|
||||||
|
} R_END_TRY_CATCH;
|
||||||
|
}
|
||||||
|
|
||||||
return ResultSuccess;
|
return ResultSuccess;
|
||||||
R_DEBUG_END
|
R_DEBUG_END
|
||||||
|
|
Loading…
Reference in a new issue