Reland "Replace sigslot usages with robocaller library."

This is a reland of 40261c3663fe316cfe40262c59cee993165ccf63

Note: Instead of changing the type of JsepTransportController->SignalSSLHandshakeError
added a new member with a different name and used it in webrtc code.
After this change do two more follow up CLs to completely remove the old code
from google3.

Original change's description:
> Replace sigslot usages with robocaller library.
>
> - Replace all the top level signals from jsep_transport_controller.
> - There are still sigslot usages in this file so keep the inheritance
>   and that is the reason for not having a binary size gain in this CL.
>
> Bug: webrtc:11943
> Change-Id: I249d3b9710783aef70ba273e082ceeafe3056898
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/185540
> Commit-Queue: Lahiru Ginnaliya Gamathige <glahiru@webrtc.org>
> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#32321}

Bug: webrtc:11943
Change-Id: Ia07394ee395f94836f6b576c3a97d119a7678e1a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/186946
Commit-Queue: Lahiru Ginnaliya Gamathige <glahiru@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#32359}
This commit is contained in:
Lahiru Ginnaliya Gamathige
2020-10-08 13:55:10 -07:00
committed by Commit Bot
parent 0591fbb031
commit c5f7108758
11 changed files with 105 additions and 55 deletions

View File

@ -816,6 +816,7 @@ rtc_library("rtc_base") {
deps = [
":checks",
":deprecation",
":robo_caller",
":rtc_task_queue",
":stringutils",
"../api:array_view",

View File

@ -33,6 +33,7 @@
#include "rtc_base/openssl_adapter.h"
#include "rtc_base/openssl_digest.h"
#include "rtc_base/openssl_identity.h"
#include "rtc_base/robo_caller.h"
#include "rtc_base/ssl_certificate.h"
#include "rtc_base/stream.h"
#include "rtc_base/task_utils/to_queued_task.h"
@ -931,6 +932,7 @@ int OpenSSLStreamAdapter::ContinueSSL() {
RTC_DLOG(LS_VERBOSE) << " -- error " << code << ", " << err_code << ", "
<< ERR_GET_REASON(err_code);
SignalSSLHandshakeError(ssl_handshake_err);
SSLHandshakeErrorSignal.Send(ssl_handshake_err);
return (ssl_error != 0) ? ssl_error : -1;
}

View File

@ -19,6 +19,7 @@
#include "absl/memory/memory.h"
#include "rtc_base/deprecation.h"
#include "rtc_base/robo_caller.h"
#include "rtc_base/ssl_certificate.h"
#include "rtc_base/ssl_identity.h"
#include "rtc_base/stream.h"
@ -268,7 +269,9 @@ class SSLStreamAdapter : public StreamAdapterInterface {
// authentication.
bool GetClientAuthEnabled() const { return client_auth_enabled_; }
// TODO(bugs.webrtc.org/11943): Remove sigslot and use one variable.
sigslot::signal1<SSLHandshakeError> SignalSSLHandshakeError;
webrtc::RoboCaller<SSLHandshakeError> SSLHandshakeErrorSignal;
private:
// If true (default), the client is required to provide a certificate during