aboutsummaryrefslogtreecommitdiff
path: root/crypto/openssl/ssl/statem/statem_dtls.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/openssl/ssl/statem/statem_dtls.c')
-rw-r--r--crypto/openssl/ssl/statem/statem_dtls.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/crypto/openssl/ssl/statem/statem_dtls.c b/crypto/openssl/ssl/statem/statem_dtls.c
index 4052ef6219b8..f62b757721fc 100644
--- a/crypto/openssl/ssl/statem/statem_dtls.c
+++ b/crypto/openssl/ssl/statem/statem_dtls.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2005-2025 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2005-2026 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the Apache License 2.0 (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -1177,7 +1177,11 @@ int dtls1_buffer_message(SSL_CONNECTION *s, int is_ccs)
return 0;
}
- pqueue_insert(s->d1->sent_messages, item);
+ if (pqueue_insert(s->d1->sent_messages, item) == NULL) {
+ dtls1_hm_fragment_free(frag);
+ pitem_free(item);
+ return 0;
+ }
return 1;
}