From 73813261b1ea9b84eb8778c2e0fec4e6e34572ea Mon Sep 17 00:00:00 2001 From: Pankaj Garg Date: Fri, 26 Jun 2020 20:10:18 +0000 Subject: [PATCH] Address review comments --- examples/lock-app/nrf5/main/Server.cpp | 2 +- examples/wifi-echo/server/esp32/main/EchoServer.cpp | 2 +- src/transport/SecureSessionMgr.h | 4 ++-- src/transport/tests/TestSecureSessionMgr.cpp | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/lock-app/nrf5/main/Server.cpp b/examples/lock-app/nrf5/main/Server.cpp index 4726595a91d32e..6f5d0c1b20462e 100644 --- a/examples/lock-app/nrf5/main/Server.cpp +++ b/examples/lock-app/nrf5/main/Server.cpp @@ -116,7 +116,7 @@ void SetupTransport(IPAddressType type, SecureSessionMgr * transport) err = transport->Init(EXAMPLE_SERVER_NODEID, &DeviceLayer::InetLayer, UdpListenParameters().SetAddressType(type)); SuccessOrExit(err); - transport->AssignCallbackObject(&gCallbacks); + transport->SetDelegate(&gCallbacks); exit: if (err != CHIP_NO_ERROR) diff --git a/examples/wifi-echo/server/esp32/main/EchoServer.cpp b/examples/wifi-echo/server/esp32/main/EchoServer.cpp index a93cb51935e582..2f580ce110491c 100644 --- a/examples/wifi-echo/server/esp32/main/EchoServer.cpp +++ b/examples/wifi-echo/server/esp32/main/EchoServer.cpp @@ -259,7 +259,7 @@ void setupTransport(IPAddressType type, SecureSessionMgr * transport, EchoServer cb->mTransport = transport; - transport->AssignCallbackObject(cb); + transport->SetDelegate(cb); exit: if (err != CHIP_NO_ERROR) diff --git a/src/transport/SecureSessionMgr.h b/src/transport/SecureSessionMgr.h index 9f48ccc38a2aca..c206912c640dca 100644 --- a/src/transport/SecureSessionMgr.h +++ b/src/transport/SecureSessionMgr.h @@ -68,7 +68,7 @@ class DLL_EXPORT SecureSessionMgrCallback : public ReferenceCounted * @details * Release if there was an existing callback object */ - void AssignCallbackObject(SecureSessionMgrCallback * cb) + void SetDelegate(SecureSessionMgrCallback * cb) { if (mCB != nullptr) { diff --git a/src/transport/tests/TestSecureSessionMgr.cpp b/src/transport/tests/TestSecureSessionMgr.cpp index b56ed464ee4c9f..88e997bfa02fef 100644 --- a/src/transport/tests/TestSecureSessionMgr.cpp +++ b/src/transport/tests/TestSecureSessionMgr.cpp @@ -123,7 +123,7 @@ void CheckMessageTest(nlTestSuite * inSuite, void * inContext) TestSessMgrCallback cb; cb.mSuite = inSuite; - conn.AssignCallbackObject(&cb); + conn.SetDelegate(&cb); cb.NewConnectionHandlerCallCount = 0; err = conn.Connect(kDestinationNodeId, Transport::PeerAddress::UDP(addr));