Commit Graph

2189 Commits

Author SHA1 Message Date
Christopher Kohlhoff
c65f3bd163 Refactor the detail::consuming_buffers template.
The consuming_buffers template, which is used internally by the composed
read and write operations, did not correctly satisfy the buffer sequence
requirements as its iterator was not bidirectional. Rather than acting
as a proxy buffer sequence, the reworked consuming_buffers template
instead produces fixed-size buffer sequences as required.
2016-08-28 10:02:41 +10:00
Marcel Raad
062b19c97b Add compatibility with OpenSSL 1.1
- SSLv2 has been completely removed from OpenSSL, even without OPENSSL_NO_SSL2
- there is a new threading API without locking callbacks
- struct SSL_CTX has been made opaque and must be used via accessor functions
- some cleanup functions have been removed
2016-08-26 12:42:50 +02:00
Christopher Kohlhoff
0999ec96d1 Regenerate documentation. 2016-08-25 09:19:31 +10:00
Christopher Kohlhoff
87ecd843d3 Disable io_context::work when ASIO_NO_DEPRECATED is defined. 2016-08-25 09:19:31 +10:00
Christopher Kohlhoff
cbcaf259cf Update requirements, overview and quick reference. 2016-08-25 09:19:30 +10:00
Christopher Kohlhoff
4d199b84de Add tsify.pl script. 2016-08-25 08:19:39 +10:00
Christopher Kohlhoff
24bdca2061 Deprecate error_code returns on synchronous operations. 2016-08-25 08:19:38 +10:00
Christopher Kohlhoff
c1f2a3b735 Add ASIO_NO_EXTENSIONS to disable the non-TS parts of the API. 2016-08-25 08:19:38 +10:00
Christopher Kohlhoff
0f6478c9c9 Update copyright notices. 2016-08-25 07:24:35 +10:00
Christopher Kohlhoff
7b8815ea41 Make unit tests work when ASIO_NO_DEPRECATED is defined. 2016-08-25 07:24:35 +10:00
Christopher Kohlhoff
7ea623bbc4 Update asio/ts/* header files to match networking TS. 2016-08-25 07:24:35 +10:00
Christopher Kohlhoff
5316fbba3b Don't include deadline_timer headers when Boost.Date_Time is disabled. 2016-08-25 07:24:34 +10:00
Christopher Kohlhoff
16120e1bd7 New const/mutable buffer sequence requirements.
The buffer sequence requirements are now defined in terms of new functions
buffer_sequence_begin() and buffer_sequence_end(). As a result, the
mutable_buffer and const_buffer classes satisfy the buffer sequence
requirements. The mutable_buffers_1 and const_buffers_1 classes have been
deprecated.
2016-08-25 07:24:34 +10:00
Christopher Kohlhoff
6176a69c81 Rename header to 'net' to match TS. 2016-08-25 07:24:34 +10:00
Christopher Kohlhoff
cacd7e9a8e Add timed run functions to the io_context.
This change adds the run_for, run_until, run_one_for and run_one_until
functions to the io_context class.
2016-08-25 07:24:34 +10:00
Christopher Kohlhoff
8a380c97ff Don't use deprecated functions in io_context unit test. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
9f2f461ac4 Add io_context::count_type typedef. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
c2077b2d88 Deprecate io_context run functions that have an error_code parameter. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
4d37def638 Add forward declaration header as specified by TS. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
826d26497e Fix typedefs for system_clock and steady_clock when std::chrono is used. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
b39b750f4c Add support for service identification using the key_type typedef. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
36302fc75b Make example executors shallow const. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
a6b948a53f Ignore io_context unit test binary. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
6c303a2efd Fix forwarding async operations in buffered streams. 2016-08-25 07:24:33 +10:00
Christopher Kohlhoff
5bebdf6e8c Update use_future interface and implementation.
This change makes use_future consistent with the networking TS. In
particular, the package() function has been removed; this functionality
is now accessed via use_future::operator().
2016-08-25 07:24:32 +10:00
Christopher Kohlhoff
62d26b6709 Add two-parameter async_result specialisations for basic_yield_context. 2016-08-25 07:24:32 +10:00
Christopher Kohlhoff
7a46efd8bf New async_result with two template parameters.
This change makes async_result consistent with the networking TS.

The older single-parameter form of async_result, and the handler_type
trait, have been deprecated. They have been retained for backwards
compatibility, and existing specialisations of these traits will still
be used. However, asynchronous operations that use the older form of
async_result/handler_type will not interoperate with completion tokens
that specialize only the new two-parameter async_result. For this
reason, the completion token types implemented by asio continue to
provide specialisations of the older form of async_result and
handler_type.
2016-08-25 07:24:32 +10:00
Christopher Kohlhoff
428ec47e43 Update list of installed headers. 2016-08-25 07:24:32 +10:00
Christopher Kohlhoff
f932359a47 Add socket() accessor to iostreams. Make basic_socket_streambuf::error() public.
The public inheritance of basic_socket_streambuf<> from basic_socket<> has been
deprecated. A reference to the underlying socket can now be obtained via the
basic_socket_iostream::socket() or basic_socket_streambuf::socket() member
functions.

The basic_socket_streambuf::puberror() function has been deprecated. The
basic_socket_streambuf::error() function should be used instead.
2016-08-25 07:24:32 +10:00
Christopher Kohlhoff
9fb2d82fbe Add move support for resolver objects. 2016-08-25 07:24:32 +10:00
Christopher Kohlhoff
a1f71f95c4 Make is_executor<> trait automatic. 2016-08-25 07:24:32 +10:00
Christopher Kohlhoff
3dd8a77afa Remove the service template parameters, and the corresponding classes.
For example, instead of basic_socket<Protocol, SocketService> we now have
simply basic_socket<Protocol>. The old interface can be enabled by defining
the ASIO_ENABLE_OLD_SERVICES macro.
2016-08-25 07:24:31 +10:00
Christopher Kohlhoff
44f3ade708 Support for building with OpenSSL when OPENSSL_NO_SSL3 is defined. 2015-12-08 17:34:33 +11:00
Christopher Kohlhoff
722f7e2be0 Add std::bind examples to handler type requirements. 2015-12-03 12:36:00 +11:00
Christopher Kohlhoff
608a1789ea Fix handling tracking to work with shallow-const executors. 2015-12-03 11:38:13 +11:00
Christopher Kohlhoff
de40487bc7 Add note about not destroying an SSL stream while there are pending operations. 2015-12-03 10:52:21 +11:00
Christopher Kohlhoff
726fb27680 Fix move constructor used by regex-based async_read_until. 2015-12-03 10:33:28 +11:00
Christopher Kohlhoff
5fa8053983 BoringSSL does not provide CONF_modules_unload. 2015-11-19 10:28:04 +11:00
Christopher Kohlhoff
92bfc623e6 Add new error category and constant for ssl::error::stream_truncated.
This error replaces uses of SSL_R_SHORT_READ, and indicates that the
SSL stream has been shut down abruptly. (I.e. the underlying socket
has been closed without performing an SSL-layer shutdown.)
2015-11-19 10:26:03 +11:00
Christopher Kohlhoff
e9fd1c9727 Regenerate certificates for SSL example. 2015-11-19 10:07:23 +11:00
Christopher Kohlhoff
b79642e7c7 Use CreateEventW rather than CreateEvent. 2015-11-19 10:07:23 +11:00
Christopher Kohlhoff
7d8916137d Pass correct output buffer size to strncat. 2015-11-19 10:07:23 +11:00
Christopher Kohlhoff
eb22276c3b Binders need to use decay to work correctly with references. 2015-10-27 11:03:42 +11:00
Christopher Kohlhoff
d4f7d5cae9 Make executors shallow-const. 2015-10-25 18:32:12 -10:00
Christopher Kohlhoff
fe7dbb75f0 Suppress unused typedef warning when using clang. 2015-10-01 08:47:25 +10:00
Christopher Kohlhoff
6c70257e20 Use SSL_CTX_clear_chain_certs, if available. 2015-10-01 08:44:30 +10:00
Christopher Kohlhoff
522ce627c6 Add aliases for chrono facilities. 2015-06-24 17:19:08 +10:00
Christopher Kohlhoff
8fa67b79ca Refactor detection of compiler thread support. 2015-06-16 08:42:13 +10:00
Christopher Kohlhoff
583e059ae6 Fix MSVC warning. 2015-06-03 09:37:08 +10:00
Christopher Kohlhoff
e2c60ab0b8 Enable noexcept for newer MSVCs. 2015-06-03 09:33:07 +10:00