diff --git a/api/rtc_error.h b/api/rtc_error.h index 673a79a2a1..904a619a5d 100644 --- a/api/rtc_error.h +++ b/api/rtc_error.h @@ -220,6 +220,7 @@ class RTCErrorOr { // NOTE: Not explicit - we want to use RTCErrorOr as a return type // so it is convenient and sensible to be able to do 'return T()' // when the return type is RTCErrorOr. + RTCErrorOr(const T& value) : value_(value) {} // NOLINT RTCErrorOr(T&& value) : value_(std::move(value)) {} // NOLINT // Delete the copy constructor and assignment operator; there aren't any use diff --git a/pc/peer_connection.cc b/pc/peer_connection.cc index 10901496f0..e0479d134a 100644 --- a/pc/peer_connection.cc +++ b/pc/peer_connection.cc @@ -6016,7 +6016,7 @@ RTCErrorOr PeerConnection::GetEarlyBundleGroup( "has no BUNDLE group"); } } - return std::move(bundle_group); + return bundle_group; } RTCError PeerConnection::CreateChannels(const SessionDescription& desc) {