mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-05-28 13:44:11 -04:00
kern: add InfoType_IsSvcPermitted
This commit is contained in:
parent
ef1b67b87b
commit
14e768cd10
7 changed files with 73 additions and 0 deletions
|
@ -285,6 +285,18 @@ namespace ams::kern::svc {
|
|||
*out = tick_count;
|
||||
}
|
||||
break;
|
||||
case ams::svc::InfoType_IsSvcPermitted:
|
||||
{
|
||||
/* Verify the input handle is invalid. */
|
||||
R_UNLESS(handle == ams::svc::InvalidHandle, svc::ResultInvalidHandle());
|
||||
|
||||
/* Verify the sub-type is valid. */
|
||||
R_UNLESS(info_subtype == svc::SvcId_SynchronizePreemptionState, svc::ResultInvalidCombination());
|
||||
|
||||
/* Get whether the svc is permitted. */
|
||||
*out = GetCurrentProcess().IsPermittedSvc(static_cast<svc::SvcId>(info_subtype));
|
||||
}
|
||||
break;
|
||||
case ams::svc::InfoType_MesosphereMeta:
|
||||
{
|
||||
/* Verify the handle is invalid. */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue