ssl/ssl_sess.c:731: error: INTEGER_OVERFLOW_L2
  ([0, 1+max(0, `ctx->sessions->num_items`)] - 1):unsigned64 by call to `remove_session_lock`.
Showing all 13 steps of the trace


ssl/ssl_sess.c:665:1: Parameter `ctx->sessions->num_items`
663.   }
664.   
665. > int SSL_CTX_add_session(SSL_CTX *ctx, SSL_SESSION *c)
666.   {
667.       int ret = 0;

ssl/ssl_sess.c:681:9: Call
679.   
680.       CRYPTO_THREAD_write_lock(ctx->lock);
681.       s = lh_SSL_SESSION_insert(ctx->sessions, c);
               ^
682.   
683.       /*

ssl/ssl_locl.h:728:1: Parameter `lh->num_items`
  726.   } TLSEXT_INDEX;
  727.   
  728. > DEFINE_LHASH_OF(SSL_SESSION);
  729.   /* Needed in ssl_cert.c */
  730.   DEFINE_LHASH_OF(X509_NAME);

ssl/ssl_locl.h:728:1: Call
  726.   } TLSEXT_INDEX;
  727.   
  728. > DEFINE_LHASH_OF(SSL_SESSION);
  729.   /* Needed in ssl_cert.c */
  730.   DEFINE_LHASH_OF(X509_NAME);

crypto/lhash/lhash.c:94:1: Parameter `lh->num_items`
    92.   }
    93.   
    94. > void *OPENSSL_LH_insert(OPENSSL_LHASH *lh, void *data)
    95.   {
    96.       unsigned long hash;

ssl/ssl_sess.c:731:22: Call
729.           if (SSL_CTX_sess_get_cache_size(ctx) > 0) {
730.               while (SSL_CTX_sess_number(ctx) > SSL_CTX_sess_get_cache_size(ctx)) {
731.                   if (!remove_session_lock(ctx, ctx->session_cache_tail, 0))
                            ^
732.                       break;
733.                   else

ssl/ssl_sess.c:747:1: Parameter `ctx->sessions->num_items`
  745.   }
  746.   
  747. > static int remove_session_lock(SSL_CTX *ctx, SSL_SESSION *c, int lck)
  748.   {
  749.       SSL_SESSION *r;

ssl/ssl_sess.c:757:17: Call
  755.           if ((r = lh_SSL_SESSION_retrieve(ctx->sessions, c)) != NULL) {
  756.               ret = 1;
  757.               r = lh_SSL_SESSION_delete(ctx->sessions, r);
                         ^
  758.               SSL_SESSION_list_remove(ctx, r);
  759.           }

ssl/ssl_locl.h:728:1: Parameter `lh->num_items`
    726.   } TLSEXT_INDEX;
    727.   
    728. > DEFINE_LHASH_OF(SSL_SESSION);
    729.   /* Needed in ssl_cert.c */
    730.   DEFINE_LHASH_OF(X509_NAME);

ssl/ssl_locl.h:728:1: Call
    726.   } TLSEXT_INDEX;
    727.   
    728. > DEFINE_LHASH_OF(SSL_SESSION);
    729.   /* Needed in ssl_cert.c */
    730.   DEFINE_LHASH_OF(X509_NAME);

crypto/lhash/lhash.c:126:1: <LHS trace>
124.   }
125.   
126. > void *OPENSSL_LH_delete(OPENSSL_LHASH *lh, const void *data)
127.   {
128.       unsigned long hash;

crypto/lhash/lhash.c:126:1: Parameter `lh->num_items`
      124.   }
      125.   
      126. > void *OPENSSL_LH_delete(OPENSSL_LHASH *lh, const void *data)
      127.   {
      128.       unsigned long hash;

crypto/lhash/lhash.c:146:5: Binary operation: ([0, 1+max(0, ctx->sessions->num_items)] - 1):unsigned64 by call to `remove_session_lock` 
      144.       }
      145.   
      146.       lh->num_items--;
                 ^
      147.       if ((lh->num_nodes > MIN_NODES) &&
      148.           (lh->down_load >= (lh->num_items * LH_LOAD_MULT / lh->num_nodes)))
