Add async sub-library to libcrypto
[openssl.git] / ssl / d1_lib.c
index 733973b332fa4311e2188c3675397e9a4b95fd4c..6e70c56ce75a9aa06304f9d78143a4bcdb848cb2 100644 (file)
@@ -155,7 +155,7 @@ int dtls1_new(SSL *s)
     d1->link_mtu = 0;
     d1->mtu = 0;
 
-    if (!d1->buffered_messages || !d1->sent_messages) {
+    if (d1->buffered_messages == NULL || d1->sent_messages == NULL) {
         pqueue_free(d1->buffered_messages);
         pqueue_free(d1->sent_messages);
         OPENSSL_free(d1);
@@ -1023,12 +1023,6 @@ int dtls1_heartbeat(SSL *s)
         return -1;
     }
 
-    /*
-     * Check if padding is too long, payload and padding must not exceed 2^14
-     * - 3 = 16381 bytes in total.
-     */
-    OPENSSL_assert(payload + padding <= 16381);
-
     /*-
      * Create HeartBeat message, we just use a sequence number
      * as payload to distuingish different messages and add