websock: compatibility for LWS without plugins
This commit is contained in:
parent
209dfd69fc
commit
f9f37a7a48
1 changed files with 6 additions and 2 deletions
|
|
@ -724,9 +724,13 @@ namespace xo {
|
|||
*/
|
||||
void init_cx_config(lws_context_creation_info * p_cx_config) {
|
||||
::memset(p_cx_config, 0, sizeof(*p_cx_config));
|
||||
p_cx_config->port = this->ws_config_.port();
|
||||
p_cx_config->port = this->ws_config_.port();
|
||||
p_cx_config->vhost_name = "localhost";
|
||||
p_cx_config->pvo = &(this->pvo_);
|
||||
#if defined(LWS_WITH_PLUGINS)
|
||||
p_cx_config->pvo = &(this->pvo_);
|
||||
#else
|
||||
p_cx_config->pvo = nullptr;
|
||||
#endif
|
||||
p_cx_config->protocols = this->protocol_v_.data();
|
||||
p_cx_config->mounts = &(this->mount_static_);
|
||||
/* userdata -- accessible from context with lws_context_user() */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue