[PATCH] Catch SSL errors