add lws_is_ssl api

Suggested by Michael Harbler on the mailing list

Signed-off-by: Andy Green <andy.green@linaro.org>
http keepalive needs to reinit some header union state

AG moved the code to the keepalive loop location