mirror of
https://github.com/kunkundi/crossdesk.git
synced 2025-10-27 04:35:34 +08:00
[feat] LeaveConnection() method needs to specific which transmission wants to leave
This commit is contained in:
@@ -81,13 +81,13 @@ int JoinConnection(PeerPtr *peer_ptr, const char *transmission_id,
|
||||
return ret;
|
||||
}
|
||||
|
||||
int LeaveConnection(PeerPtr *peer_ptr) {
|
||||
int LeaveConnection(PeerPtr *peer_ptr, const char *transmission_id) {
|
||||
if (!peer_ptr) {
|
||||
LOG_ERROR("peer_ptr not created");
|
||||
return -1;
|
||||
}
|
||||
|
||||
peer_ptr->peer_connection->Leave();
|
||||
peer_ptr->peer_connection->Leave(transmission_id);
|
||||
LOG_INFO("LeaveConnection");
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user