Commit Graph

172 Commits

Author SHA1 Message Date
Peter Thorson
e203dbed45 package for 0.3.0 release 2014-08-09 14:06:22 -05:00
Peter Thorson
ad2932bbff Disable open timeout when duration is set to zero 2014-07-24 21:39:12 -05:00
Takatoshi Kondo
296f61b595 Added a semicolon. 2014-07-08 17:15:19 +09:00
Peter Thorson
c39777e4c1 add documentation for socket policies 2014-05-30 16:02:06 -05:00
Peter Thorson
af7149ae0a Adds read_all method to iostream transport
Adds `connection::read_all(...)` method to iostream transport as a
convenience method for reading all data into the connection buffer
without the end user needing to manually loop on `read_some`.
2014-05-22 21:10:58 -05:00
Peter Thorson
7137105a81 documentation updates 2014-04-02 11:57:04 -05:00
Peter Thorson
edb26d7721 listen errors are now reported to the caller 2014-03-06 19:01:11 -06:00
Peter Thorson
b805689f9c whitespace and don't accept if we know the transport isn't listening references #334 2014-03-04 06:45:00 -06:00
Peter Thorson
5e2fadd826 pass better information about TLS handshake failures 2014-03-03 17:09:55 -06:00
Peter Thorson
840bb6b59e code style and whitespace 2014-03-03 10:32:04 -06:00
Aydan Yumerefendi
337bf2fb0a Fix memory leak on create
If the socket fails to initialize, e.g., by omitting the tis init
handler, the connection is leaked, since there is a circular reference
between the connection and its async_read/async_write handlers. To fix
this, check the error code, and reset the handler is an error has
occurred.
2014-03-03 11:08:24 -05:00
Peter Thorson
c5b5492e5c fix memory leak when a connection fails references #323 2014-03-02 22:12:38 -06:00
Peter Thorson
bdeb4ad680 code style and documentation 2014-03-02 21:39:34 -06:00
Peter Thorson
86325b1838 cleans up the handling of TLS related transport errors
Specifically: TLS short read is separated from other TLS errors. Other
TLS errors are also not separated from generic “pass through” errors.

TLS short read is now considered “expected” during socket shutdown and
is not reported as an error.
2014-02-28 09:02:26 -06:00
Peter Thorson
2d2312a1d7 add socket/security policies to translate asio -> websocketpp error codes
The reason these were added to the socket policies rather than higher
up is that in some cases translating error codes requires information
from headers and libraries that are not present except when certain
socket policies are being used. For example, SSL/TLS related errors can
only be translated using openssl, which is only pulled in with the TLS
socket policy.
2014-02-28 09:00:45 -06:00
Peter Thorson
afc28be004 whitespace 2014-02-28 08:27:29 -06:00
Peter Thorson
d36925ce7d Add new generic TLS error code 2014-02-28 08:26:50 -06:00
Peter Thorson
fe85de763e Adds configurable SO_REUSEADDR option. references #311 2014-02-02 18:12:30 -06:00
Peter Thorson
c7ec97795a add C++11 nullptr support detection 2014-02-02 17:03:41 -06:00
Peter Thorson
5f3b92c9e4 Fix compile time conflict with Visual Studio's MIN/MAX macros. 2014-02-02 10:58:02 -06:00
Peter Thorson
373f180638 re-classify some errors with more specific codes and more appropriate logging levels 2014-01-26 20:50:31 -06:00
Peter Thorson
c2f2cb951b Fixes some calls to empty lib::functions, references #310 2013-12-10 22:02:22 -06:00
Peter Thorson
827f3678bb Fixes a leak of connection objects when using asio transport references #310 2013-11-26 22:05:26 -06:00
Peter Thorson
06cdf43dcf Add start_perpetual and stop_perpetual to asio transport
These may be used to replace manually managed `asio::io_service::work`
objects
2013-11-04 16:50:35 -06:00
Peter Thorson
7032e6940f adds tcp pre and post init setting functionality to endpoint 2013-11-03 13:32:17 -06:00
Peter Thorson
bfd50e1ee1 locks and spacing 2013-11-03 13:25:21 -06:00
Peter Thorson
8993b34b3d Allows changing the listen backlog queue length 2013-11-02 19:32:38 -05:00
Peter Thorson
430c49d394 splits tcp init into pre and post init 2013-11-02 18:25:21 -05:00
Peter Thorson
3e5404e1b1 split handler allocator into separate one for reads and writes 2013-11-02 18:24:14 -05:00
Peter Thorson
aa74d2b295 switched asio read and write handler to use a custom allocator 2013-10-20 13:09:37 -05:00
Peter Thorson
746389efab removes some range checking in an inner read loop 2013-10-20 13:05:46 -05:00
Peter Thorson
5894601291 caches callback functions rather than copying them from handler to handler 2013-10-20 13:03:32 -05:00
Peter Thorson
17c9831449 cache the binding of async read and write handler callbacks 2013-10-20 12:57:02 -05:00
Peter Thorson
45a612f44b additional support for compile time disabling of multithreading features 2013-10-20 12:54:59 -05:00
Peter Thorson
1e97f6c67c statically bind the async_read_handler 2013-10-16 08:23:42 -05:00
Peter Thorson
ed39a6ab1a Re-introduces strands to asio transport 2013-10-06 14:58:29 -05:00
Peter Thorson
b934e71ace adjust transport async_accept and async_connect to use connection_ptr instead of connection_hdl
prevents a newly created connection_ptr from being destroyed
immediately after accepting or connecting.
2013-10-06 10:51:41 -05:00
Peter Thorson
e91d6f6a45 refactor iostream read completion to remove memory leak 2013-09-28 07:56:41 -05:00
Peter Thorson
de6d15c9fc adds documentation notes about when fatal_error and eof methods showed up 2013-09-28 07:56:03 -05:00
Peter Thorson
3035c8dc0a Deprecates iostream transport readsome in favor of read_some
which is more consistent with the naming of the rest of the library.
2013-09-28 07:55:41 -05:00
Peter Thorson
c175ec4f42 Adds preliminary signaling to iostream transport of eof and fatal transport errors 2013-09-27 21:24:33 -05:00
Peter Thorson
e6319f51a4 Updates transport code to use shared rather than raw pointers. references #293 2013-09-26 07:43:10 -05:00
Peter Thorson
12d240ff09 fix typo 2013-08-12 11:25:12 -05:00
Peter Thorson
107d3c9bb6 add set_remote_endpoint method to iostream transport 2013-08-12 11:22:45 -05:00
Peter Thorson
49c07296dd iostream transport documentation 2013-08-12 11:22:26 -05:00
Peter Thorson
8475f5f200 add iostream transport set_secure functionality 2013-08-12 11:21:41 -05:00
Peter Thorson
8ef8372af1 transport policy documentation 2013-08-12 11:16:59 -05:00
Peter Thorson
4a10d8ddfd iostream transport docs and code style 2013-08-12 11:16:45 -05:00
Peter Thorson
a2d92c9a21 style and documentation 2013-08-05 08:28:22 -05:00
Peter Thorson
3bab403c1b Refactor asio_transport and add full docs and exception free varient methods 2013-07-27 11:24:24 -05:00