Project homepage Mailing List  Warmcat.com  API Docs  Github Mirror 
{"schema":"libjg2-1", "vpath":"/git/", "avatar":"/git/avatar/", "alang":"", "gen_ut":1750053048, "reponame":"libwebsockets", "desc":"libwebsockets lightweight C networking library", "owner": { "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" },"url":"https://libwebsockets.org/repo/libwebsockets", "f":3, "items": [ {"schema":"libjg2-1", "cid":"5f7c5f45a2db90be075b436f4ff2fff1", "commit": {"type":"commit", "time": 1590565212, "time_ofs": 60, "oid_tree": { "oid": "203dc9f3c2a0cecdc4b81a7156281e8e3eb7ceff", "alias": []}, "oid":{ "oid": "280c81278dcb88c074aa19cbf8de809e366a9ece", "alias": []}, "msg": "ws: remove now unused ws_ping_pong_interval", "sig_commit": { "git_time": { "time": 1590565212, "offset": 60 }, "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" }, "sig_author": { "git_time": { "time": 1589394206, "offset": 60 }, "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" }}, "body": "ws: remove now unused ws_ping_pong_interval\n\nhttps://github.com/warmcat/libwebsockets/issues/1915" , "diff": "diff --git a/include/libwebsockets/lws-context-vhost.h b/include/libwebsockets/lws-context-vhost.h\nindex 3022aea..e0b71bf 100644\n--- a/include/libwebsockets/lws-context-vhost.h\n+++ b/include/libwebsockets/lws-context-vhost.h\n@@ -446,18 +446,6 @@ struct lws_context_creation_info {\n \t/**\u003c VHOST: Any bits set here will be set as server SSL options */\n \tlong ssl_options_clear;\n \t/**\u003c VHOST: Any bits set here will be cleared as server SSL options */\n-\tunsigned short ws_ping_pong_interval;\n-\t/**\u003c CONTEXT: 0 for none, else interval in seconds between sending\n-\t * PINGs on idle websocket connections. When the PING is sent,\n-\t * the PONG must come within the normal timeout_secs timeout period\n-\t * or the connection will be dropped.\n-\t * Any RX or TX traffic on the connection restarts the interval timer,\n-\t * so a connection which always sends or receives something at intervals\n-\t * less than the interval given here will never send PINGs / expect\n-\t * PONGs. Conversely as soon as the ws connection is established, an\n-\t * idle connection will do the PING / PONG roundtrip as soon as\n-\t * ws_ping_pong_interval seconds has passed without traffic\n-\t */\n \tconst struct lws_protocol_vhost_options *headers;\n \t\t/**\u003c VHOST: pointer to optional linked list of per-vhost\n \t\t * canned headers that are added to server responses */\ndiff --git a/lib/core/context.c b/lib/core/context.c\nindex f0383a5..36ed5e0 100644\n--- a/lib/core/context.c\n+++ b/lib/core/context.c\n@@ -550,8 +550,6 @@ lws_create_context(const struct lws_context_creation_info *info)\n \telse\n \t\tcontext-\u003etimeout_secs \u003d 5;\n \n-\tcontext-\u003ews_ping_pong_interval \u003d info-\u003ews_ping_pong_interval;\n-\n \tlwsl_info(\u0022 default timeout (secs): %u\u005cn\u0022, context-\u003etimeout_secs);\n \n \tif (info-\u003emax_http_header_data)\ndiff --git a/lib/core/private-lib-core.h b/lib/core/private-lib-core.h\nindex f908a2f..08abcb5 100644\n--- a/lib/core/private-lib-core.h\n+++ b/lib/core/private-lib-core.h\n@@ -513,7 +513,6 @@ struct lws_context {\n \tshort plugin_protocol_count;\n \tshort plugin_extension_count;\n \tshort server_string_len;\n-\tunsigned short ws_ping_pong_interval;\n \tunsigned short deprecation_pending_listen_close_count;\n #if defined(LWS_WITH_SECURE_STREAMS_PROXY_API)\n \tuint16_t\tss_proxy_port;\ndiff --git a/lib/roles/http/server/lejp-conf.c b/lib/roles/http/server/lejp-conf.c\nindex 15789e8..86b2550 100644\n--- a/lib/roles/http/server/lejp-conf.c\n+++ b/lib/roles/http/server/lejp-conf.c\n@@ -40,7 +40,7 @@ static const char * const paths_global[] \u003d {\n \t\u0022global.init-ssl\u0022,\n \t\u0022global.server-string\u0022,\n \t\u0022global.plugin-dir\u0022,\n-\t\u0022global.ws-pingpong-secs\u0022,\n+\t\u0022global.ws-pingpong-secs\u0022, /* deprecated */\n \t\u0022global.timeout-secs\u0022,\n \t\u0022global.reject-service-keywords[].*\u0022,\n \t\u0022global.reject-service-keywords[]\u0022,\n@@ -328,8 +328,7 @@ lejp_globals_cb(struct lejp_ctx *ctx, char reason)\n \t\ta-\u003eplugin_dirs[a-\u003ecount_plugin_dirs++] \u003d a-\u003ep;\n \t\tbreak;\n \n-\tcase LWJPGP_PINGPONG_SECS:\n-\t\ta-\u003einfo-\u003ews_ping_pong_interval \u003d atoi(ctx-\u003ebuf);\n+\tcase LWJPGP_PINGPONG_SECS: /* deprecated */\n \t\treturn 0;\n \n \tcase LWJPGP_TIMEOUT_SECS:\n@@ -403,7 +402,6 @@ lejp_vhosts_cb(struct lejp_ctx *ctx, char reason)\n #if defined(LWS_WITH_SERVER)\n \t\tss \u003d a-\u003einfo-\u003eserver_string;\n #endif\n-\t\ti[2] \u003d a-\u003einfo-\u003ews_ping_pong_interval;\n \t\ti[3] \u003d a-\u003einfo-\u003etimeout_secs;\n \n \t\tmemset(a-\u003einfo, 0, sizeof(*a-\u003einfo));\n@@ -413,7 +411,6 @@ lejp_vhosts_cb(struct lejp_ctx *ctx, char reason)\n #if defined(LWS_WITH_SERVER)\n \t\ta-\u003einfo-\u003eserver_string \u003d ss;\n #endif\n-\t\ta-\u003einfo-\u003ews_ping_pong_interval \u003d i[2];\n \t\ta-\u003einfo-\u003etimeout_secs \u003d i[3];\n \n \t\ta-\u003einfo-\u003eprotocols \u003d a-\u003eprotocols;\ndiff --git a/minimal-examples/dbus-server/minimal-dbus-ws-proxy/main.c b/minimal-examples/dbus-server/minimal-dbus-ws-proxy/main.c\nindex f926c80..066a20a 100644\n--- a/minimal-examples/dbus-server/minimal-dbus-ws-proxy/main.c\n+++ b/minimal-examples/dbus-server/minimal-dbus-ws-proxy/main.c\n@@ -79,7 +79,6 @@ int main(int argc, const char **argv)\n \tinfo.options \u003d LWS_SERVER_OPTION_DO_SSL_GLOBAL_INIT |\n \t\tLWS_SERVER_OPTION_HTTP_HEADERS_SECURITY_BEST_PRACTICES_ENFORCE;\n \tinfo.port \u003d CONTEXT_PORT_NO_LISTEN;\n-\tinfo.ws_ping_pong_interval \u003d 30;\n \tinfo.protocols \u003d protocols;\n \tinfo.pvo \u003d \u0026pvo;\n \ndiff --git a/minimal-examples/ws-server/minimal-ws-server-timer/minimal-ws-server.c b/minimal-examples/ws-server/minimal-ws-server-timer/minimal-ws-server.c\nindex 4288767..0fe5391 100644\n--- a/minimal-examples/ws-server/minimal-ws-server-timer/minimal-ws-server.c\n+++ b/minimal-examples/ws-server/minimal-ws-server-timer/minimal-ws-server.c\n@@ -111,7 +111,6 @@ int main(int argc, const char **argv)\n \tinfo.mounts \u003d \u0026mount;\n \tinfo.protocols \u003d protocols;\n \tinfo.vhost_name \u003d \u0022localhost\u0022;\n-\tinfo.ws_ping_pong_interval \u003d 10;\n \tinfo.options \u003d\n \t\tLWS_SERVER_OPTION_HTTP_HEADERS_SECURITY_BEST_PRACTICES_ENFORCE;\n \ndiff --git a/minimal-examples/ws-server/minimal-ws-server/minimal-ws-server.c b/minimal-examples/ws-server/minimal-ws-server/minimal-ws-server.c\nindex ea29f36..9e911ad 100644\n--- a/minimal-examples/ws-server/minimal-ws-server/minimal-ws-server.c\n+++ b/minimal-examples/ws-server/minimal-ws-server/minimal-ws-server.c\n@@ -85,7 +85,6 @@ int main(int argc, const char **argv)\n \tinfo.mounts \u003d \u0026mount;\n \tinfo.protocols \u003d protocols;\n \tinfo.vhost_name \u003d \u0022localhost\u0022;\n-\tinfo.ws_ping_pong_interval \u003d 10;\n \tinfo.options \u003d\n \t\tLWS_SERVER_OPTION_HTTP_HEADERS_SECURITY_BEST_PRACTICES_ENFORCE;\n \ndiff --git a/test-apps/test-client.c b/test-apps/test-client.c\nindex 73bb6d6..5247852 100644\n--- a/test-apps/test-client.c\n+++ b/test-apps/test-client.c\n@@ -547,7 +547,6 @@ static struct option options[] \u003d {\n \t{ \u0022longlived\u0022,\tno_argument,\t\tNULL, 'l' },\n \t{ \u0022post\u0022,\tno_argument,\t\tNULL, 'o' },\n \t{ \u0022once\u0022,\tno_argument,\t\tNULL, 'O' },\n-\t{ \u0022pingpong-secs\u0022, required_argument,\tNULL, 'P' },\n \t{ \u0022ssl-cert\u0022, required_argument,\tNULL, 'C' },\n \t{ \u0022ssl-key\u0022, required_argument,\tNULL, 'K' },\n \t{ \u0022ssl-ca\u0022, required_argument,\t\tNULL, 'A' },\n@@ -575,8 +574,7 @@ static int ratelimit_connects(unsigned int *last, unsigned int secs)\n int main(int argc, char **argv)\n {\n \tint n \u003d 0, m, ret \u003d 0, port \u003d 7681, use_ssl \u003d 0, ietf_version \u003d -1;\n-\tunsigned int rl_dumb \u003d 0, rl_mirror \u003d 0, do_ws \u003d 1, pp_secs \u003d 0,\n-\t\t do_multi \u003d 0;\n+\tunsigned int rl_dumb \u003d 0, rl_mirror \u003d 0, do_ws \u003d 1, do_multi \u003d 0;\n \tstruct lws_context_creation_info info;\n \tstruct lws_client_connect_info i;\n \tstruct lws_context *context;\n@@ -597,9 +595,9 @@ int main(int argc, char **argv)\n \n \twhile (n \u003e\u003d 0) {\n #if defined(LWS_HAS_GETOPT_LONG) || defined(WIN32)\n- n \u003d getopt_long(argc, argv, \u0022Sjnuv:hsp:d:lC:K:A:P:moeO\u0022, options, NULL);\n+ n \u003d getopt_long(argc, argv, \u0022Sjnuv:hsp:d:lC:K:A:moeO\u0022, options, NULL);\n #else\n- n \u003d getopt(argc, argv, \u0022Sjnuv:hsp:d:lC:K:A:P:moeO\u0022);\n+ n \u003d getopt(argc, argv, \u0022Sjnuv:hsp:d:lC:K:A:moeO\u0022);\n #endif\n \t\tif (n \u003c 0)\n \t\t\tcontinue;\n@@ -621,10 +619,6 @@ int main(int argc, char **argv)\n \t\tcase 'e':\n \t\t\tflag_echo \u003d 1;\n \t\t\tbreak;\n-\t\tcase 'P':\n-\t\t\tpp_secs \u003d atoi(optarg);\n-\t\t\tlwsl_notice(\u0022Setting pingpong interval to %d\u005cn\u0022, pp_secs);\n-\t\t\tbreak;\n \t\tcase 'j':\n \t\t\tjustmirror \u003d 1;\n \t\t\tbreak;\n@@ -709,7 +703,6 @@ int main(int argc, char **argv)\n \tinfo.protocols \u003d protocols;\n \tinfo.gid \u003d -1;\n \tinfo.uid \u003d -1;\n-\tinfo.ws_ping_pong_interval \u003d pp_secs;\n \tinfo.extensions \u003d exts;\n \n \t/*\ndiff --git a/test-apps/test-server.c b/test-apps/test-server.c\nindex 2dc6769..ddec200 100644\n--- a/test-apps/test-server.c\n+++ b/test-apps/test-server.c\n@@ -329,7 +329,6 @@ static struct option options[] \u003d {\n #ifndef LWS_NO_DAEMONIZE\n \t{ \u0022daemonize\u0022,\tno_argument,\t\tNULL, 'D' },\n #endif\n-\t{ \u0022pingpong-secs\u0022, required_argument,\tNULL, 'P' },\n \t{ \u0022ignore-sigterm\u0022, no_argument,\tNULL, 'I' },\n \n \t{ NULL, 0, 0, 0 }\n@@ -352,7 +351,6 @@ int main(int argc, char **argv)\n \tchar ca_path[1024] \u003d \u0022\u0022;\n \tint uid \u003d -1, gid \u003d -1;\n \tint use_ssl \u003d 0;\n-\tint pp_secs \u003d 0;\n \tint opts \u003d 0;\n \tint n \u003d 0;\n #ifndef LWS_NO_DAEMONIZE\n@@ -368,9 +366,9 @@ int main(int argc, char **argv)\n \n \twhile (n \u003e\u003d 0) {\n #if defined(LWS_HAS_GETOPT_LONG) || defined(WIN32)\n-\t\tn \u003d getopt_long(argc, argv, \u0022eci:hsap:d:DC:K:A:R:vu:g:P:kU:niIr:\u0022, options, NULL);\n+\t\tn \u003d getopt_long(argc, argv, \u0022eci:hsap:d:DC:K:A:R:vu:g:kU:niIr:\u0022, options, NULL);\n #else\n-\t\tn \u003d getopt(argc, argv, \u0022eci:hsap:d:DC:K:A:R:vu:g:P:kU:nIr:\u0022);\n+\t\tn \u003d getopt(argc, argv, \u0022eci:hsap:d:DC:K:A:R:vu:g:kU:nIr:\u0022);\n #endif\n \t\tif (n \u003c 0)\n \t\t\tcontinue;\n@@ -443,10 +441,6 @@ int main(int argc, char **argv)\n \t\tcase 'A':\n \t\t\tlws_strncpy(ca_path, optarg, sizeof(ca_path));\n \t\t\tbreak;\n-\t\tcase 'P':\n-\t\t\tpp_secs \u003d atoi(optarg);\n-\t\t\tlwsl_notice(\u0022Setting pingpong interval to %d\u005cn\u0022, pp_secs);\n-\t\t\tbreak;\n #if defined(LWS_WITH_TLS)\n \t\tcase 'v':\n \t\t\tuse_ssl \u003d 1;\n@@ -511,7 +505,6 @@ int main(int argc, char **argv)\n \tinfo.protocols \u003d protocols;\n \tinfo.ssl_cert_filepath \u003d NULL;\n \tinfo.ssl_private_key_filepath \u003d NULL;\n-\tinfo.ws_ping_pong_interval \u003d pp_secs;\n \n \tif (use_ssl) {\n \t\tif (strlen(resource_path) \u003e sizeof(cert_path) - 32) {\n","s":{"c":1750053048,"u": 6953}} ],"g": 9105,"chitpc": 0,"ehitpc": 0,"indexed":0 , "ab": 0, "si": 0, "db":0, "di":0, "sat":0, "lfc": "0000"}