test/handshake_helper.c:729: error: INTEGER_OVERFLOW_L2
  ([0, +oo] - 1):unsigned64 by call to `SSL_set_session`.
Showing all 23 steps of the trace


test/handshake_helper.c:720:5: Call
718.       /* Setup SSL and buffers; additional configuration happens below. */
719.       create_peer(&server, server_ctx);
720.       create_peer(&client, client_ctx);
           ^
721.   
722.       server.bytes_to_write = client.bytes_to_read = app_data_size;

test/handshake_helper.c:428:17: Call
  426.       static const int peer_buffer_size = 64 * 1024;
  427.   
  428.       peer->ssl = SSL_new(ctx);
                         ^
  429.       TEST_check(peer->ssl != NULL);
  430.       peer->write_buf = OPENSSL_zalloc(peer_buffer_size);

ssl/ssl_lib.c:522:1: Parameter `ctx->sessions->num_items`
    520.   }
    521.   
    522. > SSL *SSL_new(SSL_CTX *ctx)
    523.   {
    524.       SSL *s;

test/handshake_helper.c:728:9: Call
726.       if (session_in != NULL) {
727.           /* In case we're testing resumption without tickets. */
728.           TEST_check(SSL_CTX_add_session(server_ctx, session_in));
               ^
729.           TEST_check(SSL_set_session(client.ssl, session_in));
730.       }

ssl/ssl_sess.c:624:1: Parameter `ctx->sessions->num_items`
  622.   }
  623.   
  624. > int SSL_CTX_add_session(SSL_CTX *ctx, SSL_SESSION *c)
  625.   {
  626.       int ret = 0;

ssl/ssl_sess.c:640:9: Call
  638.   
  639.       CRYPTO_THREAD_write_lock(ctx->lock);
  640.       s = lh_SSL_SESSION_insert(ctx->sessions, c);
                 ^
  641.   
  642.       /*

ssl/ssl_locl.h:594:1: Parameter `lh->num_items`
    592.   };
    593.   
    594. > DEFINE_LHASH_OF(SSL_SESSION);
    595.   /* Needed in ssl_cert.c */
    596.   DEFINE_LHASH_OF(X509_NAME);

ssl/ssl_locl.h:594:1: Call
    592.   };
    593.   
    594. > DEFINE_LHASH_OF(SSL_SESSION);
    595.   /* Needed in ssl_cert.c */
    596.   DEFINE_LHASH_OF(X509_NAME);

crypto/lhash/lhash.c:70:1: Parameter `lh->num_items`
      68.   }
      69.   
      70. > void *OPENSSL_LH_insert(OPENSSL_LHASH *lh, void *data)
      71.   {
      72.       unsigned long hash;

test/handshake_helper.c:729:9: Call
727.           /* In case we're testing resumption without tickets. */
728.           TEST_check(SSL_CTX_add_session(server_ctx, session_in));
729.           TEST_check(SSL_set_session(client.ssl, session_in));
               ^
730.       }
731.   

ssl/ssl_sess.c:777:1: Parameter `s->initial_ctx->sessions->num_items`
  775.   }
  776.   
  777. > int SSL_set_session(SSL *s, SSL_SESSION *session)
  778.   {
  779.       ssl_clear_bad_session(s);

ssl/ssl_sess.c:779:5: Call
  777.   int SSL_set_session(SSL *s, SSL_SESSION *session)
  778.   {
  779.       ssl_clear_bad_session(s);
             ^
  780.       if (s->ctx->method != s->method) {
  781.           if (!SSL_set_ssl_method(s, s->ctx->method))

ssl/ssl_sess.c:991:1: Parameter `s->initial_ctx->sessions->num_items`
    989.   }
    990.   
    991. > int ssl_clear_bad_session(SSL *s)
    992.   {
    993.       if ((s->session != NULL) &&

ssl/ssl_sess.c:996:9: Call
    994.           !(s->shutdown & SSL_SENT_SHUTDOWN) &&
    995.           !(SSL_in_init(s) || SSL_in_before(s))) {
    996.           SSL_CTX_remove_session(s->session_ctx, s->session);
                   ^
    997.           return (1);
    998.       } else

ssl/ssl_sess.c:693:1: Parameter `ctx->sessions->num_items`
      691.   }
      692.   
      693. > int SSL_CTX_remove_session(SSL_CTX *ctx, SSL_SESSION *c)
      694.   {
      695.       return remove_session_lock(ctx, c, 1);

ssl/ssl_sess.c:695:12: Call
      693.   int SSL_CTX_remove_session(SSL_CTX *ctx, SSL_SESSION *c)
      694.   {
      695.       return remove_session_lock(ctx, c, 1);
                        ^
      696.   }
      697.   

ssl/ssl_sess.c:698:1: Parameter `ctx->sessions->num_items`
        696.   }
        697.   
        698. > static int remove_session_lock(SSL_CTX *ctx, SSL_SESSION *c, int lck)
        699.   {
        700.       SSL_SESSION *r;

ssl/ssl_sess.c:708:17: Call
        706.           if ((r = lh_SSL_SESSION_retrieve(ctx->sessions, c)) == c) {
        707.               ret = 1;
        708.               r = lh_SSL_SESSION_delete(ctx->sessions, c);
                               ^
        709.               SSL_SESSION_list_remove(ctx, c);
        710.           }

ssl/ssl_locl.h:594:1: Parameter `lh->num_items`
          592.   };
          593.   
          594. > DEFINE_LHASH_OF(SSL_SESSION);
          595.   /* Needed in ssl_cert.c */
          596.   DEFINE_LHASH_OF(X509_NAME);

ssl/ssl_locl.h:594:1: Call
          592.   };
          593.   
          594. > DEFINE_LHASH_OF(SSL_SESSION);
          595.   /* Needed in ssl_cert.c */
          596.   DEFINE_LHASH_OF(X509_NAME);

crypto/lhash/lhash.c:103:1: <LHS trace>
101.   }
102.   
103. > void *OPENSSL_LH_delete(OPENSSL_LHASH *lh, const void *data)
104.   {
105.       unsigned long hash;

crypto/lhash/lhash.c:103:1: Parameter `lh->num_items`
            101.   }
            102.   
            103. > void *OPENSSL_LH_delete(OPENSSL_LHASH *lh, const void *data)
            104.   {
            105.       unsigned long hash;

crypto/lhash/lhash.c:123:5: Binary operation: ([0, +oo] - 1):unsigned64 by call to `SSL_set_session` 
            121.       }
            122.   
            123.       lh->num_items--;
                       ^
            124.       if ((lh->num_nodes > MIN_NODES) &&
            125.           (lh->down_load >= (lh->num_items * LH_LOAD_MULT / lh->num_nodes)))
