Add checks for NULL return from EC_KEY_get0_group()