Andy Green [Mon, 14 Feb 2011 20:25:43 +0000 (20:25 +0000)]
break client connect into states and apply timeout
Doing a client connect was atomic until now, blocking
all the other service while it waited for proxy and / or
server response.
This patch uses the new timeout system and breaks the
client connect sequence into three states handled by
the normal poll() processing. It means that there are
now no blocking network delays and it's all handled
by the main state machine.
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 14 Feb 2011 17:59:43 +0000 (17:59 +0000)]
introduce timeout system
This adds a concept of timeouts for operations enforced by
connection closure if the timeout is reached.
Once a second all sockets are checked for timing out, every time
there is a service call it checks to see if a second has passed since
the last check and checks if so.
You can also call libwebsocket_service_fd() with a NULL fd to give
the timeouts a chance to be detected; if it's less than a second since
the last check it returns immediately.
Signed-off-by: Andy Green <andy@warmcat.com>
Timothy J Fontaine [Mon, 14 Feb 2011 17:55:27 +0000 (17:55 +0000)]
Fix refactor damage from missed debug-only print arg
Just a quick follow up there is a compile error at the moment, which I
think is resolved as the following?
Signed-off-by: Timothy J Fontaine <tjfontaine@gmail.com>
Darin Willits [Mon, 14 Feb 2011 17:52:39 +0000 (17:52 +0000)]
Apple / iOS build compatability patch
This allows build on iOS platform, thanks Darin!
Signed-off-by: Darin Willits <darin@willits.ca>
Andy Green [Mon, 14 Feb 2011 09:14:25 +0000 (09:14 +0000)]
introduce this param in callback fix server close on client socket
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 14 Feb 2011 09:14:24 +0000 (09:14 +0000)]
eliminate dummy 76 challenge content in 04 plus
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 14 Feb 2011 08:03:48 +0000 (08:03 +0000)]
unify server and client close
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 13 Feb 2011 09:15:10 +0000 (09:15 +0000)]
clean-out-poll-array-when-hanging-up-on-client.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sun, 13 Feb 2011 09:08:11 +0000 (09:08 +0000)]
uplevel-rpm-spec-to-include-new-extpoll-sample.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sun, 13 Feb 2011 09:05:54 +0000 (09:05 +0000)]
use-new-peer-name-api-in-ping.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sun, 13 Feb 2011 09:04:21 +0000 (09:04 +0000)]
introduce-libwebsockets_hangup_on_client.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sun, 13 Feb 2011 08:54:05 +0000 (08:54 +0000)]
add-example-protocol-handshake-filter-callback.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sun, 13 Feb 2011 08:40:37 +0000 (08:40 +0000)]
add-example-network-filter-callback.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sun, 13 Feb 2011 08:37:12 +0000 (08:37 +0000)]
introduce-network-connect-filter-callback.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sun, 13 Feb 2011 08:25:26 +0000 (08:25 +0000)]
introduce-user-handshake-filter-callback.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sat, 12 Feb 2011 21:24:03 +0000 (21:24 +0000)]
document-external-poll-support.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sat, 12 Feb 2011 13:15:04 +0000 (13:15 +0000)]
add-ext-poll-callbacks-in-extpoll-test.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sat, 12 Feb 2011 13:14:11 +0000 (13:14 +0000)]
introduce-external-poll-callbacks.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sat, 12 Feb 2011 12:07:23 +0000 (12:07 +0000)]
introduce-libwebsockets-test-server-extpoll.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sat, 12 Feb 2011 11:57:45 +0000 (11:57 +0000)]
export-libwebsocket_service_fd-api.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Sat, 12 Feb 2011 11:57:43 +0000 (11:57 +0000)]
decouple-service-from-fd-array-index.patch
This patch removes the relationship between position in the
pollfd[] array and any meaning about the type of socket.
It also refactors the service loop so there is a per-fd
function that detects the mode of the connection and services
it accordingly.
The context wsi * array is removed and a hashtable introduced
allowing fast wsi lookup from just the fd that it is
associated with
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 10 Feb 2011 09:32:24 +0000 (09:32 +0000)]
optimize-random-device-open.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Thu, 10 Feb 2011 09:22:35 +0000 (09:22 +0000)]
optimize-server-for-all-zero-nonce-case.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Thu, 10 Feb 2011 09:07:05 +0000 (09:07 +0000)]
introduce-new-05-socket-closure-rules.patch
Signed-off-by: Andy Green <andy.green@linaro.org>
Andy Green [Wed, 9 Feb 2011 08:58:42 +0000 (08:58 +0000)]
parse-and-reject-extensions-header.patch
Signed-off-by: Andy Green <andy@linaro.org>
Andy Green [Wed, 9 Feb 2011 08:49:14 +0000 (08:49 +0000)]
introduce-ietf-05-framing-and-commandline-options.patch
This adds 05 support, and -v switches on test-client and test-ping
to allow setting their ietf protocol version to 4 or 5.
It also optimizes the masking to us a function pointer, which
takes some conditionals out of the fast path.
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Wed, 9 Feb 2011 07:16:34 +0000 (07:16 +0000)]
change-client-mode-to-enum.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 6 Feb 2011 17:42:06 +0000 (17:42 +0000)]
fix-hostname-to-be-server-name--allow-switches-in-any-order.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Tue, 1 Feb 2011 08:52:55 +0000 (08:52 +0000)]
fix-error-path-on-server-headers-wrong.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 21:04:24 +0000 (21:04 +0000)]
add-k-opt-to-test-client.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 20:57:25 +0000 (20:57 +0000)]
introduce-k-switch-defeat-masking.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 20:40:32 +0000 (20:40 +0000)]
fix-context-close.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 12:15:25 +0000 (12:15 +0000)]
introduce-multiple-client-ping.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 12:15:22 +0000 (12:15 +0000)]
fix-client-close.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 11:43:51 +0000 (11:43 +0000)]
add-user-allocation-for-client-connects.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 08:24:31 +0000 (08:24 +0000)]
introduce-LWS_WRITE_CLIENT_IGNORE_XOR_MASK.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 30 Jan 2011 08:10:02 +0000 (08:10 +0000)]
clean-style.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 28 Jan 2011 10:00:18 +0000 (10:00 +0000)]
fix-host-header-contents--introduce-canonical-hostname-api.patch
I?aki pointed out the dummy host field used in client test and ping
is not valid http. This patch changes it to use the actual host
name and adds an api to collect that from the context cheaply.
Reported-by: I?aki Baz Castillo <ibc@aliax.net>
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 28 Jan 2011 09:39:29 +0000 (09:39 +0000)]
cleanup-proxy-code--add-timeout.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 28 Jan 2011 09:01:19 +0000 (09:01 +0000)]
correct-proxy-fail-connect-handling.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 27 Jan 2011 22:01:43 +0000 (22:01 +0000)]
introduce-http_proxy-support-no-auth.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 27 Jan 2011 20:06:03 +0000 (20:06 +0000)]
introduce-test-ping-app.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 27 Jan 2011 06:53:39 +0000 (06:53 +0000)]
add-test-client-rpm-spec.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 27 Jan 2011 06:45:53 +0000 (06:45 +0000)]
workaround-32bit-size_t.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 27 Jan 2011 06:36:39 +0000 (06:36 +0000)]
uplevel-soname-and-spec-0.3.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 27 Jan 2011 06:26:52 +0000 (06:26 +0000)]
introduce-ssl-client-connections--flow-control.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 23 Jan 2011 17:53:54 +0000 (17:53 +0000)]
document-new-config-options.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 23 Jan 2011 17:47:08 +0000 (17:47 +0000)]
introduce-private-md5-sha1.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 23 Jan 2011 16:50:33 +0000 (16:50 +0000)]
clean--fix-sigpipe.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sat, 22 Jan 2011 12:51:57 +0000 (12:51 +0000)]
introduce-client-support.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 20 Jan 2011 10:23:50 +0000 (10:23 +0000)]
add-enable-nofork-config-option.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Wed, 19 Jan 2011 13:11:55 +0000 (13:11 +0000)]
expose-event-loop.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Wed, 19 Jan 2011 12:20:27 +0000 (12:20 +0000)]
introduce-04-control-frames.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Tue, 18 Jan 2011 18:14:26 +0000 (18:14 +0000)]
introduce-new-04-frame-unmasking.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Tue, 18 Jan 2011 17:45:00 +0000 (17:45 +0000)]
introduce-new-04-masking-key-computation.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Tue, 18 Jan 2011 17:14:03 +0000 (17:14 +0000)]
introduce-new-04-handshake.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Tue, 18 Jan 2011 15:39:02 +0000 (15:39 +0000)]
introduce-new-04-headers-logic.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Tue, 18 Jan 2011 15:39:02 +0000 (15:39 +0000)]
add-base64-encode-decode.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Tue, 18 Jan 2011 15:29:04 +0000 (15:29 +0000)]
use-enum-for-demo-protocols.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 20 Dec 2010 09:35:03 +0000 (09:35 +0000)]
use-libcrypto-hash-implementations.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 20 Dec 2010 09:19:37 +0000 (09:19 +0000)]
clean--move-v2-support-to-claim-v3.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 19 Dec 2010 22:25:16 +0000 (22:25 +0000)]
uplevel-rpm-soname.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 19 Dec 2010 22:13:26 +0000 (22:13 +0000)]
clean-whitespace.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 19 Dec 2010 20:50:01 +0000 (20:50 +0000)]
clean-and-add-pedantic-remove-long-long.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sat, 18 Dec 2010 15:13:50 +0000 (15:13 +0000)]
fork-sever-process-and-introduce-broadcast-api.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 15 Nov 2010 22:08:00 +0000 (22:08 +0000)]
fix-md5-problem.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 15 Nov 2010 19:39:30 +0000 (19:39 +0000)]
fix-script-to-synthesize-websocket-url-entirely-from-script-url.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 15 Nov 2010 17:03:26 +0000 (17:03 +0000)]
add-rpm-spec-file.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 15 Nov 2010 15:36:59 +0000 (15:36 +0000)]
md5-move-to-using-standard-accessor-macros-for-le.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 15 Nov 2010 12:46:25 +0000 (12:46 +0000)]
remove-md5-struct.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sat, 13 Nov 2010 10:03:47 +0000 (10:03 +0000)]
coding-style-cleanups.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 12 Nov 2010 14:12:13 +0000 (14:12 +0000)]
mirror-protocol-chrome-and-firefox.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 12 Nov 2010 13:11:50 +0000 (13:11 +0000)]
add-INSTALL.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 12 Nov 2010 13:10:40 +0000 (13:10 +0000)]
introduce-mirror-test-protocol.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 12 Nov 2010 11:47:39 +0000 (11:47 +0000)]
fix-revents-inherited-from-old-socket-bug.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 12 Nov 2010 11:15:49 +0000 (11:15 +0000)]
fix-user-pointer-bug.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 12 Nov 2010 10:44:18 +0000 (10:44 +0000)]
remove-last-fork.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Fri, 12 Nov 2010 10:44:16 +0000 (10:44 +0000)]
move-to-automatic-protocol-list-scheme.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 11 Nov 2010 13:19:19 +0000 (13:19 +0000)]
test-applet-add-reset-button-and-colour-socket-status.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 11 Nov 2010 12:52:28 +0000 (12:52 +0000)]
require-specific-test-protocol.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 11 Nov 2010 12:48:13 +0000 (12:48 +0000)]
add-Sec-WebSocket-Draft-and-protocol-autodetect.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 11 Nov 2010 12:29:23 +0000 (12:29 +0000)]
eliminate-accessor-apis.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 11 Nov 2010 12:28:29 +0000 (12:28 +0000)]
add-protocol-filter.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Thu, 11 Nov 2010 09:22:22 +0000 (09:22 +0000)]
fix-rx-action-76.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Wed, 10 Nov 2010 11:57:07 +0000 (11:57 +0000)]
remove symlinks-from-automake-missing
Andy Green [Tue, 9 Nov 2010 11:04:41 +0000 (11:04 +0000)]
remove-symlinks-from-automake-missing.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 21:04:23 +0000 (21:04 +0000)]
style-cleanups.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 20:58:54 +0000 (20:58 +0000)]
refactor-md5-code.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 20:20:42 +0000 (20:20 +0000)]
break-out-lib-sources.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 17:28:21 +0000 (17:28 +0000)]
add-documentation-script-to-automake.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 17:16:50 +0000 (17:16 +0000)]
add-depcomp.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 17:12:19 +0000 (17:12 +0000)]
add-COPYING-lgpl-2.1.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 17:04:09 +0000 (17:04 +0000)]
convert-to-autotools.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 8 Nov 2010 17:03:03 +0000 (17:03 +0000)]
add-wss-ssl-openssl-support.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Wed, 3 Nov 2010 11:19:23 +0000 (11:19 +0000)]
change-api-docs-to-html.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Wed, 3 Nov 2010 11:13:06 +0000 (11:13 +0000)]
add-per-session-user-data.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Wed, 3 Nov 2010 08:25:13 +0000 (08:25 +0000)]
move-debug-to-DEBUG-define.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 1 Nov 2010 09:20:48 +0000 (09:20 +0000)]
test-assets-into-usr-share.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Mon, 1 Nov 2010 09:12:17 +0000 (09:12 +0000)]
refactor-into-dirs.patch
Signed-off-by: Andy Green <andy@warmcat.com>
Andy Green [Sun, 31 Oct 2010 17:51:39 +0000 (17:51 +0000)]
add-kernel-doc-script-and-generated-api.txt
Signed-off-by: Andy Green <andy@warmcat.com>