diff --git a/src/protocols/bdx/AsyncTransferFacilitator.cpp b/src/protocols/bdx/AsyncTransferFacilitator.cpp index dada77ad51d3be..826903e3824b08 100644 --- a/src/protocols/bdx/AsyncTransferFacilitator.cpp +++ b/src/protocols/bdx/AsyncTransferFacilitator.cpp @@ -34,7 +34,6 @@ void AsyncTransferFacilitator::Reset() CHIP_ERROR AsyncTransferFacilitator::SendMessage(TransferSession::OutputEvent & event) { - VerifyOrReturnError(mExchange, CHIP_ERROR_INCORRECT_STATE); Messaging::SendFlags sendFlags; diff --git a/src/protocols/bdx/AsyncTransferFacilitator.h b/src/protocols/bdx/AsyncTransferFacilitator.h index 370d5ece701678..9d830c1b127c46 100644 --- a/src/protocols/bdx/AsyncTransferFacilitator.h +++ b/src/protocols/bdx/AsyncTransferFacilitator.h @@ -51,13 +51,9 @@ class AsyncTransferFacilitator : public Messaging::ExchangeDelegate virtual void HandleTransferSessionOutput(TransferSession::OutputEvent & event) = 0; /** - * This method should be implemented to clean up and destroy the instance of the sub class - * implemeting it and the base class. - * - * Note: After this method has been called, we can't use the instance of the subclass that - * implements this. + * This method should be implemented to destroy the object subclassing AsyncTransferFacilitator. */ - virtual void CleanUp() = 0; + virtual void DestroySelf() = 0; protected: CHIP_ERROR OnMessageReceived(Messaging::ExchangeContext * ec, const PayloadHeader & payloadHeader, @@ -67,7 +63,7 @@ class AsyncTransferFacilitator : public Messaging::ExchangeDelegate CHIP_ERROR SendMessage(TransferSession::OutputEvent & event); - // The transfer session coresponding to this AsynTransferFacilitator object. + // The transfer session coresponding to this AsyncTransferFacilitator object. TransferSession mTransfer; // The Exchange holder that holds the exchange context used for BDX messages. @@ -84,10 +80,10 @@ class AsyncTransferFacilitator : public Messaging::ExchangeDelegate /** * An AsyncTransferFacilitator that is initialized to respond to an incoming BDX transfer request. * - * Provides a method for initializing the TransferSession member but still needs to be extended to implement + * Provides a method for initializing the TransferSession members but still needs to be extended to implement * HandleTransferSessionOutput. * - * This class, or a subclass of it, should be used as the exchange delegate for a BDX transfer. + * An instance of some subclass of this class, should be used as the exchange delegate for a BDX transfer. */ class AsyncResponder : public AsyncTransferFacilitator {