summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibTLS
diff options
context:
space:
mode:
authorsin-ack <sin-ack@users.noreply.github.com>2021-08-30 18:12:48 +0000
committerAli Mohammad Pur <Ali.mpfard@gmail.com>2021-09-02 03:47:47 +0430
commit8ea22121ac8fe0c0e3a073ecd607713f45b34ff3 (patch)
treedbdfc49938925ea75a70894d2c5de47912184c6b /Userland/Libraries/LibTLS
parente9121f8b1f9d31f0da89f34eac69a7da9f2901a0 (diff)
downloadserenity-8ea22121ac8fe0c0e3a073ecd607713f45b34ff3.zip
Userland: Migrate to argument-less deferred_invoke
Only one place used this argument and it was to hold on to a strong ref for the object. Since we already do that now, there's no need to keep this argument around since this can be easily captured. This commit contains no changes.
Diffstat (limited to 'Userland/Libraries/LibTLS')
-rw-r--r--Userland/Libraries/LibTLS/Record.cpp2
-rw-r--r--Userland/Libraries/LibTLS/Socket.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/Userland/Libraries/LibTLS/Record.cpp b/Userland/Libraries/LibTLS/Record.cpp
index a94c170a86..02314b52c6 100644
--- a/Userland/Libraries/LibTLS/Record.cpp
+++ b/Userland/Libraries/LibTLS/Record.cpp
@@ -41,7 +41,7 @@ void TLSv12::write_packet(ByteBuffer& packet)
if (m_context.connection_status > ConnectionStatus::Disconnected) {
if (!m_has_scheduled_write_flush) {
dbgln_if(TLS_DEBUG, "Scheduling write of {}", m_context.tls_buffer.size());
- deferred_invoke([this](auto&) { write_into_socket(); });
+ deferred_invoke([this] { write_into_socket(); });
m_has_scheduled_write_flush = true;
} else {
// multiple packet are available, let's flush some out
diff --git a/Userland/Libraries/LibTLS/Socket.cpp b/Userland/Libraries/LibTLS/Socket.cpp
index 2df6980a4d..536b52bf7e 100644
--- a/Userland/Libraries/LibTLS/Socket.cpp
+++ b/Userland/Libraries/LibTLS/Socket.cpp
@@ -97,7 +97,7 @@ bool TLSv12::common_connect(const struct sockaddr* saddr, socklen_t length)
auto packet = build_hello();
write_packet(packet);
- deferred_invoke([&](auto&) {
+ deferred_invoke([&] {
m_handshake_timeout_timer = Core::Timer::create_single_shot(
m_max_wait_time_for_handshake_in_seconds * 1000, [&] {
auto timeout_diff = Core::DateTime::now().timestamp() - m_context.handshake_initiation_timestamp;
@@ -141,7 +141,7 @@ void TLSv12::read_from_socket()
auto notify_client_for_app_data = [&] {
if (m_context.application_buffer.size() > 0) {
if (!did_schedule_read) {
- deferred_invoke([&](auto&) { read_from_socket(); });
+ deferred_invoke([&] { read_from_socket(); });
did_schedule_read = true;
}
if (on_tls_ready_to_read)