// // Automatically generated by ipdlc. // Edit at your own risk // #include "mozilla/PRemoteMediaManagerParent.h" #include "gfxipc/ShadowLayerUtils.h" #include "mozilla/GfxMessageUtils.h" #include "mozilla/ProfilerLabels.h" #include "mozilla/RemoteMediaManagerParent.h" #include "mozilla/dom/MediaIPCUtils.h" #include "mozilla/ipc/IPCCore.h" #include "mozilla/layers/CompositorTypes.h" #include "mozilla/layers/LayersMessageUtils.h" #include "mozilla/layers/WebRenderMessageUtils.h" #include "mozilla/layers/PTextureParent.h" #include "mozilla/PRemoteCDMParent.h" #include "mozilla/PRemoteDecoderParent.h" #include "mozilla/PRemoteEncoderParent.h" #include "ipc/IPCMessageUtils.h" #include "ipc/IPCMessageUtilsSpecializations.h" #include "nsIFile.h" #include "mozilla/ipc/Endpoint.h" #include "mozilla/ipc/ProtocolMessageUtils.h" #include "mozilla/ipc/ProtocolUtils.h" #include "mozilla/ipc/ShmemMessageUtils.h" #include "mozilla/ipc/TaintingIPCUtils.h" namespace mozilla { auto PRemoteMediaManagerParent::RecvPRemoteDecoderConstructor( PRemoteDecoderParent* actor, const RemoteDecoderInfoIPDL& info, const OptionSet& options, const mozilla::Maybe& identifier, const mozilla::Maybe& mediaEngineId, const mozilla::Maybe& trackingId, PRemoteCDMParent* cdm) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PRemoteMediaManagerParent::RecvPRemoteEncoderConstructor( PRemoteEncoderParent* actor, const EncoderConfig& config) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PRemoteMediaManagerParent::RecvPRemoteCDMConstructor( PRemoteCDMParent* actor, const nsAString& keySystem) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PRemoteMediaManagerParent::ProcessingError( Result aCode, const char* aReason) -> void { } auto PRemoteMediaManagerParent::ShouldContinueFromReplyTimeout() -> bool { return true; } MOZ_IMPLICIT PRemoteMediaManagerParent::PRemoteMediaManagerParent() : mozilla::ipc::IToplevelProtocol("PRemoteMediaManagerParent", kProtocolId, mozilla::ipc::ParentSide) { MOZ_COUNT_CTOR(PRemoteMediaManagerParent); } PRemoteMediaManagerParent::~PRemoteMediaManagerParent() { MOZ_COUNT_DTOR(PRemoteMediaManagerParent); } auto PRemoteMediaManagerParent::ActorAlloc() -> void { AddRef(); } auto PRemoteMediaManagerParent::ActorDealloc() -> void { Release(); } auto PRemoteMediaManagerParent::OtherPid() const -> ::base::ProcessId { ::base::ProcessId pid = ::mozilla::ipc::IProtocol::ToplevelProtocol()->OtherPidMaybeInvalid(); MOZ_RELEASE_ASSERT(pid != ::base::kInvalidProcessId); return pid; } auto PRemoteMediaManagerParent::OtherChildID() const -> ::GeckoChildID { ::GeckoChildID childID = ::mozilla::ipc::IProtocol::ToplevelProtocol()->OtherChildIDMaybeInvalid(); MOZ_RELEASE_ASSERT(childID != -1); return childID; } auto PRemoteMediaManagerParent::OtherEndpointProcInfo() const -> ::mozilla::ipc::EndpointProcInfo { return ::mozilla::ipc::EndpointProcInfo{OtherPid(), OtherChildID()}; } auto PRemoteMediaManagerParent::ManagedPRemoteCDMParent(nsTArray& aArr) const -> void { mManagedPRemoteCDMParent.ToArray(aArr); } auto PRemoteMediaManagerParent::ManagedPRemoteCDMParent() const -> const ManagedContainer& { return mManagedPRemoteCDMParent; } auto PRemoteMediaManagerParent::ManagedPRemoteDecoderParent(nsTArray& aArr) const -> void { mManagedPRemoteDecoderParent.ToArray(aArr); } auto PRemoteMediaManagerParent::ManagedPRemoteDecoderParent() const -> const ManagedContainer& { return mManagedPRemoteDecoderParent; } auto PRemoteMediaManagerParent::ManagedPRemoteEncoderParent(nsTArray& aArr) const -> void { mManagedPRemoteEncoderParent.ToArray(aArr); } auto PRemoteMediaManagerParent::ManagedPRemoteEncoderParent() const -> const ManagedContainer& { return mManagedPRemoteEncoderParent; } auto PRemoteMediaManagerParent::ManagedProtocolIds() const -> mozilla::Span { static constexpr ::mozilla::ipc::ProtocolId sIds[] = { PRemoteCDMMsgStart, PRemoteDecoderMsgStart, PRemoteEncoderMsgStart }; return sIds; } auto PRemoteMediaManagerParent::GetManagedActors(mozilla::ipc::ProtocolId aProtocol) -> UntypedManagedContainer* { switch (aProtocol) { case PRemoteCDMMsgStart: return (&(mManagedPRemoteCDMParent)); case PRemoteDecoderMsgStart: return (&(mManagedPRemoteDecoderParent)); case PRemoteEncoderMsgStart: return (&(mManagedPRemoteEncoderParent)); default: return nullptr; } } auto PRemoteMediaManagerParent::OpenPRemoteCDMEndpoint(PRemoteCDMParent* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PRemoteCDMParent actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PRemoteCDMParent actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PRemoteMediaManagerParent::BindPRemoteCDMEndpoint( ManagedEndpoint aEndpoint, PRemoteCDMParent* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PRemoteMediaManagerParent::OpenPRemoteDecoderEndpoint(PRemoteDecoderParent* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PRemoteDecoderParent actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PRemoteDecoderParent actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PRemoteMediaManagerParent::BindPRemoteDecoderEndpoint( ManagedEndpoint aEndpoint, PRemoteDecoderParent* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PRemoteMediaManagerParent::OpenPRemoteEncoderEndpoint(PRemoteEncoderParent* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PRemoteEncoderParent actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PRemoteEncoderParent actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PRemoteMediaManagerParent::BindPRemoteEncoderEndpoint( ManagedEndpoint aEndpoint, PRemoteEncoderParent* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PRemoteMediaManagerParent::DeallocManagee( mozilla::ipc::ProtocolId aProtocolId, IProtocol* aListener) -> void { switch (aProtocolId) { default: FatalError("unreached"); return; } } auto PRemoteMediaManagerParent::OnMessageReceived(const Message& msg__) -> PRemoteMediaManagerParent::Result { if (!CanSend()) { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Ignored message for dead actor", (&(msg__))->type(), mozilla::ipc::MessageDirection::eSending); } return MsgProcessed; } IPC::Message::routeid_t route__ = msg__.routing_id(); if (MSG_ROUTING_CONTROL != route__) { IProtocol* routed__ = Lookup(route__); if (!routed__ || !routed__->GetLifecycleProxy()) { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Ignored message for dead actor", (&(msg__))->type(), mozilla::ipc::MessageDirection::eSending); } return MsgProcessed; } RefPtr proxy__ = routed__->GetLifecycleProxy(); return proxy__->Get()->OnMessageReceived(msg__); } switch (msg__.type()) { case PRemoteMediaManager::Msg_PRemoteDecoderConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PRemoteMediaManager::Msg_PRemoteDecoderConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__info = IPC::ReadParam((&(reader__))); if (!maybe__info) { FatalError("Error deserializing 'RemoteDecoderInfoIPDL'"); return MsgValueError; } auto& info = *maybe__info; // Sentinel = 'info' if ((!(((&(reader__)))->ReadSentinel(70058413)))) { mozilla::ipc::SentinelReadError("Error deserializing 'RemoteDecoderInfoIPDL'"); return MsgValueError; } auto maybe__options = IPC::ReadParam((&(reader__))); if (!maybe__options) { FatalError("Error deserializing 'OptionSet'"); return MsgValueError; } auto& options = *maybe__options; // Sentinel = 'options' if ((!(((&(reader__)))->ReadSentinel(204735245)))) { mozilla::ipc::SentinelReadError("Error deserializing 'OptionSet'"); return MsgValueError; } auto maybe__identifier = IPC::ReadParam>((&(reader__))); if (!maybe__identifier) { FatalError("Error deserializing 'TextureFactoryIdentifier?'"); return MsgValueError; } auto& identifier = *maybe__identifier; // Sentinel = 'identifier' if ((!(((&(reader__)))->ReadSentinel(379978788)))) { mozilla::ipc::SentinelReadError("Error deserializing 'TextureFactoryIdentifier?'"); return MsgValueError; } auto maybe__mediaEngineId = IPC::ReadParam>((&(reader__))); if (!maybe__mediaEngineId) { FatalError("Error deserializing 'uint64_t?'"); return MsgValueError; } auto& mediaEngineId = *maybe__mediaEngineId; // Sentinel = 'mediaEngineId' if ((!(((&(reader__)))->ReadSentinel(597624068)))) { mozilla::ipc::SentinelReadError("Error deserializing 'uint64_t?'"); return MsgValueError; } auto maybe__trackingId = IPC::ReadParam>((&(reader__))); if (!maybe__trackingId) { FatalError("Error deserializing 'TrackingId?'"); return MsgValueError; } auto& trackingId = *maybe__trackingId; // Sentinel = 'trackingId' if ((!(((&(reader__)))->ReadSentinel(381879297)))) { mozilla::ipc::SentinelReadError("Error deserializing 'TrackingId?'"); return MsgValueError; } auto maybe__cdm = IPC::ReadParam((&(reader__))); if (!maybe__cdm) { FatalError("Error deserializing 'PRemoteCDM'"); return MsgValueError; } auto& cdm = *maybe__cdm; // Sentinel = 'cdm' if ((!(((&(reader__)))->ReadSentinel(39911733)))) { mozilla::ipc::SentinelReadError("Error deserializing 'PRemoteCDM'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->AllocPRemoteDecoderParent(info, options, identifier, mediaEngineId, trackingId, cdm); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->RecvPRemoteDecoderConstructor(actor, std::move(info), std::move(options), std::move(identifier), std::move(mediaEngineId), std::move(trackingId), cdm); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PRemoteMediaManager::Msg_PRemoteEncoderConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PRemoteMediaManager::Msg_PRemoteEncoderConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__config = IPC::ReadParam((&(reader__))); if (!maybe__config) { FatalError("Error deserializing 'EncoderConfig'"); return MsgValueError; } auto& config = *maybe__config; // Sentinel = 'config' if ((!(((&(reader__)))->ReadSentinel(145097335)))) { mozilla::ipc::SentinelReadError("Error deserializing 'EncoderConfig'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->AllocPRemoteEncoderParent(config); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->RecvPRemoteEncoderConstructor(actor, std::move(config)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PRemoteMediaManager::Msg_PRemoteCDMConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PRemoteMediaManager::Msg_PRemoteCDMConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__keySystem = IPC::ReadParam((&(reader__))); if (!maybe__keySystem) { FatalError("Error deserializing 'nsString'"); return MsgValueError; } auto& keySystem = *maybe__keySystem; // Sentinel = 'keySystem' if ((!(((&(reader__)))->ReadSentinel(317785039)))) { mozilla::ipc::SentinelReadError("Error deserializing 'nsString'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->AllocPRemoteCDMParent(keySystem); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->RecvPRemoteCDMConstructor(actor, std::move(keySystem)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PRemoteMediaManager::Msg_DeallocateSurfaceDescriptorGPUVideo__ID: { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PRemoteMediaManager::Msg_DeallocateSurfaceDescriptorGPUVideo", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__sd = IPC::ReadParam((&(reader__))); if (!maybe__sd) { FatalError("Error deserializing 'SurfaceDescriptorGPUVideo'"); return MsgValueError; } auto& sd = *maybe__sd; // Sentinel = 'sd' if ((!(((&(reader__)))->ReadSentinel(21758168)))) { mozilla::ipc::SentinelReadError("Error deserializing 'SurfaceDescriptorGPUVideo'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->RecvDeallocateSurfaceDescriptorGPUVideo(std::move(sd)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PRemoteMediaManager::Msg_OnSetCurrent__ID: { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PRemoteMediaManager::Msg_OnSetCurrent", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__sd = IPC::ReadParam((&(reader__))); if (!maybe__sd) { FatalError("Error deserializing 'SurfaceDescriptorGPUVideo'"); return MsgValueError; } auto& sd = *maybe__sd; // Sentinel = 'sd' if ((!(((&(reader__)))->ReadSentinel(21758168)))) { mozilla::ipc::SentinelReadError("Error deserializing 'SurfaceDescriptorGPUVideo'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->RecvOnSetCurrent(std::move(sd)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } default: return MsgNotKnown; case SHMEM_CREATED_MESSAGE_TYPE: { if (!ShmemCreated(msg__)) { return MsgPayloadError; } return MsgProcessed; } case SHMEM_DESTROYED_MESSAGE_TYPE: { if (!ShmemDestroyed(msg__)) { return MsgPayloadError; } return MsgProcessed; } } } auto PRemoteMediaManagerParent::OnMessageReceived( const Message& msg__, UniquePtr& reply__) -> PRemoteMediaManagerParent::Result { if (!CanSend()) { return MsgDropped; } IPC::Message::routeid_t route__ = msg__.routing_id(); if (MSG_ROUTING_CONTROL != route__) { IProtocol* routed__ = Lookup(route__); if (!routed__ || !routed__->GetLifecycleProxy()) { return MsgDropped; } RefPtr proxy__ = routed__->GetLifecycleProxy(); return proxy__->Get()->OnMessageReceived(msg__, reply__); } switch (msg__.type()) { case PRemoteMediaManager::Msg_Readback__ID: { if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PRemoteMediaManager::Msg_Readback", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__sd = IPC::ReadParam((&(reader__))); if (!maybe__sd) { FatalError("Error deserializing 'SurfaceDescriptorGPUVideo'"); return MsgValueError; } auto& sd = *maybe__sd; // Sentinel = 'sd' if ((!(((&(reader__)))->ReadSentinel(21758168)))) { mozilla::ipc::SentinelReadError("Error deserializing 'SurfaceDescriptorGPUVideo'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; SurfaceDescriptor aResult{}; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::RemoteMediaManagerParent*>(this))->RecvReadback(std::move(sd), (&(aResult))); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } reply__ = PRemoteMediaManager::Reply_Readback(id__); IPC::MessageWriter writer__{ (*(reply__)), this}; IPC::WriteParam((&(writer__)), aResult); // Sentinel = 'aResult' ((&(writer__)))->WriteSentinel(185205473); if (mozilla::ipc::LoggingEnabledFor("PRemoteMediaManager", mozilla::ipc::ParentSide)) { mozilla::ipc::LogMessageForProtocol( "PRemoteMediaManagerParent", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } return MsgProcessed; } default: return MsgNotKnown; } } } // namespace mozilla