mirror of
https://github.com/owntone/owntone-server.git
synced 2025-11-21 02:09:11 -05:00
[web] Support libevent as WS server instead of libwebsockets
If libevent >= 2.2 is detected during configure and "websocket_port" == 0 in the config file, the libwebsocket implementation is disabled and instead the libevent http server offers the websocket connection. The connection to the websocket is then done with the path "/ws".
This commit is contained in:
committed by
Alain Nussbaumer
parent
fd322a2941
commit
a3ab301cff
@@ -478,7 +478,11 @@ websocket_init(void)
|
||||
|
||||
if (websocket_port <= 0)
|
||||
{
|
||||
#ifdef HAVE_LIBEVENT22
|
||||
DPRINTF(E_DBG, L_WEB, "Libwebsocket disabled, using libevent websocket instead. To enable it, set websocket_port in config to a valid port number.\n");
|
||||
#else
|
||||
DPRINTF(E_LOG, L_WEB, "Websocket disabled. To enable it, set websocket_port in config to a valid port number.\n");
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user