Skip to content

Commit df84a07

Browse files
committed
fixed compilation warning for deprecated webrtc function
1 parent 5089b19 commit df84a07

File tree

2 files changed

+33
-23
lines changed

2 files changed

+33
-23
lines changed

windows/wrapper/impl_org_webRtc.cpp

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
1-
2-
#include <zsLib/Log.h>
3-
4-
#include "Org.WebRtc.Glue.events.h"
5-
#include "Org.WebRtc.Glue.events.jman.h"
6-
7-
namespace wrapper { namespace impl { namespace org { namespace webRtc { ZS_IMPLEMENT_SUBSYSTEM(wrapper_org_webRtc); } } } }
8-
1+
2+
#include <zsLib/Log.h>
3+
4+
#include "Org.WebRtc.Glue.events.h"
5+
#include "Org.WebRtc.Glue.events.jman.h"
6+
7+
namespace wrapper { namespace impl { namespace org { namespace webRtc { ZS_IMPLEMENT_SUBSYSTEM(wrapper_org_webRtc); } } } }
8+
99
ZS_EVENTING_SUBSYSTEM_DEFAULT_LEVEL(wrapper_org_webRtc, Debug)
10-
11-
namespace wrapper {
12-
namespace impl {
13-
namespace org {
14-
namespace webRtc {
15-
16-
void initSubsystems() noexcept
17-
{
10+
11+
namespace wrapper {
12+
namespace impl {
13+
namespace org {
14+
namespace webRtc {
15+
16+
void initSubsystems() noexcept
17+
{
1818
ZS_GET_SUBSYSTEM_LOG_LEVEL(ZS_GET_OTHER_SUBSYSTEM(wrapper::impl::org::webRtc, wrapper_org_webRtc));
1919
ZS_EVENTING_REGISTER(Org_WebRtc_Glue);
20-
}
21-
22-
} // namespace webRtc
23-
} // namespace impl
24-
} // namespace org
25-
} // namespace webRtc
20+
}
21+
22+
} // namespace webRtc
23+
} // namespace impl
24+
} // namespace org
25+
} // namespace webRtc

windows/wrapper/impl_org_webRtc_RTCPeerConnection.cpp

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,12 +112,17 @@ namespace wrapper {
112112
public:
113113
typedef rtc::scoped_refptr<SessionDescriptionObserver> ObserverScopedPtr;
114114

115-
void OnSuccess(::webrtc::SessionDescriptionInterface* desc) override
115+
void OnSuccess(::webrtc::SessionDescriptionInterface* desc) final
116116
{
117117
auto wrapper = UseSessionDescription::toWrapper(desc);
118118
promise_->resolve(wrapper);
119119
}
120120

121+
void OnFailure(::webrtc::RTCError error) override
122+
{
123+
UseError::rejectPromise(promise_, error);
124+
}
125+
121126
void OnFailure(const std::string& error) override
122127
{
123128
UseError::rejectPromise(promise_, ::webrtc::RTCError(::webrtc::RTCErrorType::INVALID_PARAMETER, error.c_str()));
@@ -331,6 +336,11 @@ PromisePtr wrapper::impl::org::webRtc::RTCPeerConnection::setLocalDescription(wr
331336
promise_->resolve();
332337
}
333338

339+
void OnFailure(::webrtc::RTCError error) override
340+
{
341+
UseError::rejectPromise(promise_, error);
342+
}
343+
334344
void OnFailure(const std::string& error) override
335345
{
336346
UseError::rejectPromise(promise_, ::webrtc::RTCError(::webrtc::RTCErrorType::INVALID_PARAMETER, error.c_str()));

0 commit comments

Comments
 (0)