ipc: Add support for PopIpcInterface() method.

- This can be used for domain objects as inputs to service functions.
This commit is contained in:
bunnei 2018-04-30 23:24:31 -04:00
parent 8262aeeac8
commit fadab1d5f3
4 changed files with 23 additions and 0 deletions

View file

@ -298,6 +298,13 @@ public:
template <typename T>
Kernel::SharedPtr<T> GetCopyObject(size_t index);
template <class T>
std::shared_ptr<T> PopIpcInterface() {
ASSERT(context->Session()->IsDomain());
ASSERT(context->GetDomainMessageHeader()->input_object_count > 0);
return context->GetDomainRequestHandler<T>(Pop<u32>() - 1);
}
};
/// Pop ///