summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibTLS
diff options
context:
space:
mode:
authorTim Schumacher <timschumi@gmx.de>2022-09-13 23:44:19 +0200
committerBrian Gianforcaro <b.gianfo@gmail.com>2022-09-16 05:39:28 +0000
commit8763dbcccc48690fce6f01ce8166222bd8234a85 (patch)
treed5f6fa0d884b86d9b082e7e5d0c912ac5778391d /Userland/Libraries/LibTLS
parent643d2a683b478424847e3e9103dbf5e7c22121f1 (diff)
downloadserenity-8763dbcccc48690fce6f01ce8166222bd8234a85.zip
Everywhere: Remove a bunch of dead write-only variables
LLVM 15 now warns (and thus errors) about this, and there is really no point in keeping them.
Diffstat (limited to 'Userland/Libraries/LibTLS')
-rw-r--r--Userland/Libraries/LibTLS/HandshakeCertificate.cpp4
1 files changed, 0 insertions, 4 deletions
diff --git a/Userland/Libraries/LibTLS/HandshakeCertificate.cpp b/Userland/Libraries/LibTLS/HandshakeCertificate.cpp
index dd1bcfbad2..40bb4c6f1b 100644
--- a/Userland/Libraries/LibTLS/HandshakeCertificate.cpp
+++ b/Userland/Libraries/LibTLS/HandshakeCertificate.cpp
@@ -39,11 +39,9 @@ ssize_t TLSv12::handle_certificate(ReadonlyBytes buffer)
}
size_t size = certificate_total_length;
- size_t index = 0;
bool valid_certificate = false;
while (size > 0) {
- ++index;
if (buffer.size() - res < 3) {
dbgln_if(TLS_DEBUG, "not enough data for certificate length");
return (i8)Error::NeedMoreData;
@@ -58,14 +56,12 @@ ssize_t TLSv12::handle_certificate(ReadonlyBytes buffer)
auto res_cert = res;
auto remaining = certificate_size;
- size_t certificates_in_chain = 0;
do {
if (remaining <= 3) {
dbgln("Ran out of data");
break;
}
- ++certificates_in_chain;
if (buffer.size() < (size_t)res_cert + 3) {
dbgln("not enough data to read cert size ({} < {})", buffer.size(), res_cert + 3);
break;