mirror of
https://github.com/tsl0922/ttyd.git
synced 2025-12-28 14:34:34 +01:00
Use custom Server header in http response
This commit is contained in:
@@ -272,6 +272,12 @@ main(int argc, char **argv) {
|
||||
|
||||
lws_set_log_level(debug_level, NULL);
|
||||
|
||||
#if LWS_LIBRARY_VERSION_MAJOR == 2
|
||||
char server_hdr[128] = "";
|
||||
sprintf(server_hdr, "ttyd/%s (libwebsockets/%s)", TTYD_VERSION, LWS_LIBRARY_VERSION);
|
||||
info.server_string = server_hdr;
|
||||
#endif
|
||||
|
||||
if (strlen(iface) > 0)
|
||||
info.iface = iface;
|
||||
if (ssl) {
|
||||
|
||||
Reference in New Issue
Block a user