From e88197646d9e07e9315333a1c4fac40c16458266 Mon Sep 17 00:00:00 2001 From: Filip Klembara Date: Mon, 31 May 2021 14:52:55 +0200 Subject: [PATCH] Fix code duplication --- src/capi.cpp | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/src/capi.cpp b/src/capi.cpp index aaa64c7..a110953 100644 --- a/src/capi.cpp +++ b/src/capi.cpp @@ -401,34 +401,6 @@ int rtcDeleteDataChannel(int dc) { }); } -int rtcIsDataChannelOpen(int dc) { - return wrap([dc] { - return getDataChannel(dc)->isOpen() ? RTC_ERR_SUCCESS : RTC_ERR_FAILURE; - }); -} - -#if RTC_ENABLE_MEDIA - -void setSSRC(Description::Media *description, uint32_t ssrc, const char *_name, const char *_msid, const char *_trackID) { - - optional name = nullopt; - if (_name) { - name = string(_name); - } - - optional msid = nullopt; - if (_msid) { - msid = string(_msid); - } - - optional trackID = nullopt; - if (_trackID) { - trackID = string(_trackID); - } - - description->addSSRC(ssrc, name, msid, trackID); -} - int rtcAddTrack(int pc, const char *mediaDescriptionSdp) { return wrap([&] { if (!mediaDescriptionSdp)