Skip to content

Commit 125ef8c

Browse files
committed
add local session id to the event data
1 parent f1ee04f commit 125ef8c

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/include/platform/CHIPDeviceEvent.h

+1
Original file line numberDiff line numberDiff line change
@@ -545,6 +545,7 @@ struct ChipDeviceEvent final
545545
uint8_t FabricIndex;
546546
uint8_t SecureSessionType;
547547
uint8_t TransportType;
548+
uint16_t LocalSessionId;
548549
} SecureSessionEstablished;
549550
};
550551

src/protocols/secure_channel/PairingSession.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,9 @@ void PairingSession::Finish()
8686
event.SecureSessionEstablished.TransportType = to_underlying(address.GetTransportType());
8787
event.SecureSessionEstablished.SecureSessionType =
8888
to_underlying(mSecureSessionHolder->AsSecureSession()->GetSecureSessionType());
89-
event.SecureSessionEstablished.PeerNodeId = mSecureSessionHolder->GetPeer().GetNodeId();
90-
event.SecureSessionEstablished.FabricIndex = mSecureSessionHolder->GetPeer().GetFabricIndex();
89+
event.SecureSessionEstablished.LocalSessionId = mSecureSessionHolder->AsSecureSession()->GetLocalSessionId();
90+
event.SecureSessionEstablished.PeerNodeId = mSecureSessionHolder->GetPeer().GetNodeId();
91+
event.SecureSessionEstablished.FabricIndex = mSecureSessionHolder->GetPeer().GetFabricIndex();
9192
if (DeviceLayer::PlatformMgr().PostEvent(&event) != CHIP_NO_ERROR)
9293
{
9394
ChipLogError(SecureChannel, "Failed to post Secure Session established event");

0 commit comments

Comments
 (0)