aboutsummaryrefslogtreecommitdiffstats
path: root/src/tls/tls_channel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/tls/tls_channel.cpp')
-rw-r--r--src/tls/tls_channel.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tls/tls_channel.cpp b/src/tls/tls_channel.cpp
index 46c6d36cd..e688f354d 100644
--- a/src/tls/tls_channel.cpp
+++ b/src/tls/tls_channel.cpp
@@ -182,10 +182,10 @@ void TLS_Channel::read_handshake(byte rec_type,
}
}
-void TLS_Channel::queue_for_sending(const byte buf[], size_t buf_size)
+void TLS_Channel::send(const byte buf[], size_t buf_size)
{
- if(!handshake_completed)
- throw std::runtime_error("Application data cannot be queued before handshake");
+ if(!is_active())
+ throw std::runtime_error("Data cannot be sent on inactive TLS connection");
writer.send(APPLICATION_DATA, buf, buf_size);
}