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


test/sslapitest.c:629:10: Call
627.       }
628.   
629.       if (!create_ssl_connection(serverssl, clientssl, SSL_ERROR_NONE)) {
                ^
630.           printf("Unable to create SSL connection\n");
631.           goto end;

test/ssltestlib.c:654:20: Call
  652.           err = SSL_ERROR_WANT_WRITE;
  653.           while (!clienterr && retc <= 0 && err == SSL_ERROR_WANT_WRITE) {
  654.               retc = SSL_connect(clientssl);
                            ^
  655.               if (retc <= 0)
  656.                   err = SSL_get_error(clientssl, retc);

ssl/ssl_lib.c:1469:1: Parameter `s->session_ctx->sessions->num_items`
    1467.   }
    1468.   
    1469. > int SSL_connect(SSL *s)
    1470.   {
    1471.       if (s->handshake_func == NULL) {

ssl/ssl_lib.c:1476:12: Call
    1474.       }
    1475.   
    1476.       return SSL_do_handshake(s);
                       ^
    1477.   }
    1478.   

ssl/ssl_lib.c:3245:1: Parameter `s->session_ctx->sessions->num_items`
      3243.   }
      3244.   
      3245. > int SSL_do_handshake(SSL *s)
      3246.   {
      3247.       int ret = 1;

test/ssltestlib.c:654:20: Call
  652.           err = SSL_ERROR_WANT_WRITE;
  653.           while (!clienterr && retc <= 0 && err == SSL_ERROR_WANT_WRITE) {
  654.               retc = SSL_connect(clientssl);
                            ^
  655.               if (retc <= 0)
  656.                   err = SSL_get_error(clientssl, retc);

ssl/ssl_lib.c:1469:1: Parameter `s->session_ctx->sessions->num_items`
    1467.   }
    1468.   
    1469. > int SSL_connect(SSL *s)
    1470.   {
    1471.       if (s->handshake_func == NULL) {

ssl/ssl_lib.c:1476:12: Call
    1474.       }
    1475.   
    1476.       return SSL_do_handshake(s);
                       ^
    1477.   }
    1478.   

ssl/ssl_lib.c:3245:1: Parameter `s->session_ctx->sessions->num_items`
      3243.   }
      3244.   
      3245. > int SSL_do_handshake(SSL *s)
      3246.   {
      3247.       int ret = 1;

test/sslapitest.c:638:10: Call
636.        * doesn't leak (when using enable-crypto-mdebug).
637.        */
638.       if (!SSL_clear(serverssl)) {
                ^
639.           printf("Unexpected failure from SSL_clear()\n");
640.           goto end;

ssl/ssl_lib.c:444:1: Parameter `s->session_ctx->sessions->num_items`
  442.   }
  443.   
  444. > int SSL_clear(SSL *s)
  445.   {
  446.       if (s->method == NULL) {

ssl/ssl_lib.c:451:9: Call
  449.       }
  450.   
  451.       if (ssl_clear_bad_session(s)) {
                 ^
  452.           SSL_SESSION_free(s->session);
  453.           s->session = NULL;

ssl/ssl_sess.c:1036:1: Parameter `s->session_ctx->sessions->num_items`
    1034.   }
    1035.   
    1036. > int ssl_clear_bad_session(SSL *s)
    1037.   {
    1038.       if ((s->session != NULL) &&

ssl/ssl_sess.c:1041:9: Call
    1039.           !(s->shutdown & SSL_SENT_SHUTDOWN) &&
    1040.           !(SSL_in_init(s) || SSL_in_before(s))) {
    1041.           SSL_CTX_remove_session(s->session_ctx, s->session);
                    ^
    1042.           return (1);
    1043.       } else

ssl/ssl_sess.c:724:1: Parameter `ctx->sessions->num_items`
      722.   }
      723.   
      724. > int SSL_CTX_remove_session(SSL_CTX *ctx, SSL_SESSION *c)
      725.   {
      726.       return remove_session_lock(ctx, c, 1);

ssl/ssl_sess.c:726:12: Call
      724.   int SSL_CTX_remove_session(SSL_CTX *ctx, SSL_SESSION *c)
      725.   {
      726.       return remove_session_lock(ctx, c, 1);
                        ^
      727.   }
      728.   

ssl/ssl_sess.c:729:1: Parameter `ctx->sessions->num_items`
        727.   }
        728.   
        729. > static int remove_session_lock(SSL_CTX *ctx, SSL_SESSION *c, int lck)
        730.   {
        731.       SSL_SESSION *r;

ssl/ssl_sess.c:739:17: Call
        737.           if ((r = lh_SSL_SESSION_retrieve(ctx->sessions, c)) == c) {
        738.               ret = 1;
        739.               r = lh_SSL_SESSION_delete(ctx->sessions, c);
                               ^
        740.               SSL_SESSION_list_remove(ctx, c);
        741.           }

ssl/ssl_locl.h:688:1: Parameter `lh->num_items`
          686.   } CLIENTHELLO_MSG;
          687.   
          688. > DEFINE_LHASH_OF(SSL_SESSION);
          689.   /* Needed in ssl_cert.c */
          690.   DEFINE_LHASH_OF(X509_NAME);

ssl/ssl_locl.h:688:1: Call
          686.   } CLIENTHELLO_MSG;
          687.   
          688. > DEFINE_LHASH_OF(SSL_SESSION);
          689.   /* Needed in ssl_cert.c */
          690.   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_clear` 
            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)))
