Only free the hazard array during connection close.

We saw a case where session->hazard was NULL, so I'm hoping that avoiding any frees during runtime might help.