From 1a7341e86a72d4b5c32d0294a5ed4cb0b56f3727 Mon Sep 17 00:00:00 2001 From: Steffen Vogel Date: Sun, 21 Oct 2018 10:27:42 +0200 Subject: [PATCH] web: fix errors caused by merge --- lib/web.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/web.cpp b/lib/web.cpp index c5735d13d..78e68522f 100644 --- a/lib/web.cpp +++ b/lib/web.cpp @@ -248,15 +248,15 @@ void Web::start() throw new RuntimeError("Failed to initialize server context"); for (int tries = 10; tries > 0; tries--) { - w->vhost = lws_create_vhost(w->context, &ctx_info); - if (w->vhost) + vhost = lws_create_vhost(context, &ctx_info); + if (vhost) break; ctx_info.port++; warn("WebSocket: failed to setup vhost. Trying another port: %d", ctx_info.port); } - if (w->vhost == NULL) + if (vhost == NULL) throw new RuntimeError("Failed to initialize virtual host"); /* Start thread */