if no comparison function set make sk_sort no op

Reviewed-by: Rich Salz <rsalz@openssl.org>
This commit is contained in:
Dr. Stephen Henson 2016-02-06 17:07:58 +00:00
parent 8a07e27cd8
commit 0ca2e82ab1

View File

@ -336,7 +336,7 @@ void *sk_set(_STACK *st, int i, void *value)
void sk_sort(_STACK *st)
{
if (st && !st->sorted) {
if (st && !st->sorted && st->comp != NULL) {
int (*comp_func) (const void *, const void *);
/*