Commit 6fcace45 authored by Rich Salz's avatar Rich Salz
Browse files

GH1555: Don't bump size on realloc failure

parent 4588cb44
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -213,8 +213,8 @@ static int expand(OPENSSL_LHASH *lh)
        j = (int)lh->num_alloc_nodes * 2;
        n = OPENSSL_realloc(lh->b, (int)(sizeof(OPENSSL_LH_NODE *) * j));
        if (n == NULL) {
            /* fputs("realloc error in lhash",stderr); */
            lh->error++;
            lh->num_nodes--;
            lh->p = 0;
            return 0;
        }