Fix invariant broken in 5f1374e2.

If to_free is not a valid pointer then it should be NULL.

Change-Id: I6addb2b8e7aa61d3ba47baaf8d0606d10ff2545d
This commit is contained in:
Adam Langley 2014-10-06 19:30:44 -07:00
parent 5f1374e203
commit 57e52f2a63

View File

@ -279,6 +279,7 @@ void ERR_clear_error(void) {
}
if (state->to_free) {
OPENSSL_free(state->to_free);
state->to_free = NULL;
}
state->top = state->bottom = 0;