improve c++ compatibility

Adapted by Joakim
Subject: [PATCH] add _lws_logv to make loging accessible to other wrappers.
 use _lws_logv in _lws_log
Subject: [PATCH] add user context pointer to the protocol structure