Commit Graph

174 Commits

Author SHA1 Message Date
Christopher Kohlhoff
aea347d0a7 Add const overloads of the lowest_layer member functions.
[SVN r48535]
2008-09-02 11:34:18 +00:00
Christopher Kohlhoff
4696ee9033 Add class to allow use of arbitrary Windows overlapped I/O operations.
[SVN r48495]
2008-08-31 11:38:52 +00:00
Christopher Kohlhoff
2f86d9c815 Don't build serial port test code when serial ports are not available.
[SVN r48490]
2008-08-31 08:58:49 +00:00
Christopher Kohlhoff
bb6bfd4b5a Change the CompletionCondition concept so that:
- It is now evaluated before the first call to the underlying
  *_some() operation, as well as after every operation.
- The return value is a number of bytes, which indicates the maximum
  length to be transferred on the subsequent *_some() operation. If
  the return value is 0 then the composed operation completes.

Add missing unit tests for read_at and write_at.


[SVN r48418]
2008-08-28 12:11:47 +00:00
Christopher Kohlhoff
de4cfeb523 Use get_io_service() rather than deprecated io_service() function.
[SVN r48417]
2008-08-28 12:09:09 +00:00
Christopher Kohlhoff
10e8419c7e Some linux configurations do not automatically define _XOPEN_SOURCE.
[SVN r46876]
2008-06-30 00:24:44 +00:00
Christopher Kohlhoff
43e62310b6 Add new overloads for read_until and async_read_until that invoke a
user-defined function object to determine when a match has been found.


[SVN r46475]
2008-06-18 13:03:46 +00:00
Christopher Kohlhoff
1539f2c8a1 Add an iterator for bytewise traversal of a buffer sequence.
[SVN r46415]
2008-06-16 00:41:29 +00:00
Christopher Kohlhoff
fa82af9e16 Add random-access handles for use on Windows.
[SVN r46319]
2008-06-11 11:17:53 +00:00
Christopher Kohlhoff
7e062f298d Add support for serial ports.
[SVN r46272]
2008-06-09 12:54:55 +00:00
Christopher Kohlhoff
b466d42996 Add test for the crash that can occur when destroying a handler object that
owns its own memory (as is the case when destroying handlers in an orphaned
strand). 


[SVN r46003]
2008-06-01 01:31:25 +00:00
Christopher Kohlhoff
528e09e9f6 Fully qualify uses of asio's placeholders to resolve ambiguity with C++0x's
placeholders namespace.


[SVN r45006]
2008-05-02 07:59:01 +00:00
Christopher Kohlhoff
8768d9dff1 Fix or suppress MSVC level 4 warnings. Fixes #1703.
[SVN r44727]
2008-04-22 23:46:15 +00:00
Christopher Kohlhoff
ee449aa163 Add new wrapper classes for stream-oriented handles on Windows.
[SVN r44676]
2008-04-21 05:32:34 +00:00
Christopher Kohlhoff
1ef42e04c6 Add new wrapper classes for stream-oriented file descriptors on POSIX platforms.
[SVN r44675]
2008-04-21 05:16:15 +00:00
Christopher Kohlhoff
f784e54ced Add support for UNIX domain sockets.
[SVN r44674]
2008-04-21 04:43:05 +00:00
Christopher Kohlhoff
a277af13a5 Add a special null_buffers type that allows read and write operations to
be used to indicate the socket's readiness to read or write without
blocking.


[SVN r44673]
2008-04-21 04:02:37 +00:00
Christopher Kohlhoff
02e47999fa Update copyright notices.
[SVN r43473]
2008-03-03 14:13:01 +00:00
Christopher Kohlhoff
f99a3cb814 Update copyright notices.
[SVN r43472]
2008-03-03 14:05:35 +00:00
Christopher Kohlhoff
ff29c1bcfb Only define _XOPEN_SOURCE_EXTENDED when building with gcc on HP-UX.
[SVN r43302]
2008-02-18 13:33:23 +00:00
Christopher Kohlhoff
86dc84f36d Need to define _XOPEN_SOURCE_EXTENDED when compiling for HP-UX.
[SVN r43221]
2008-02-11 13:59:44 +00:00
Christopher Kohlhoff
09665bffa4 Ensure asio header comes before boost.thread header.
[SVN r41870]
2007-12-08 14:03:40 +00:00
Christopher Kohlhoff
771774b926 WinCE doesn't work with all multicast addresses, and even though it doesn't
support the multicast::enable_loopback option you can still get the value.


[SVN r41407]
2007-11-26 21:29:38 +00:00
Christopher Kohlhoff
33dfeb1789 Add checks for expected failures on Windows CE.
[SVN r40783]
2007-11-05 12:38:39 +00:00
Christopher Kohlhoff
2ded97148e HP-UX fails to declare if_nametoindex as extern "C". Added a declaration
for it with correct linkage to avoid a linker error.


[SVN r40549]
2007-10-29 13:08:32 +00:00
Christopher Kohlhoff
72198ee954 Fixes for HP-UX test failures.
[SVN r40413]
2007-10-24 13:23:59 +00:00
Christopher Kohlhoff
34a91ea73c Seems that the watermark socket options are supported on HP-UX 11i v3.
[SVN r40262]
2007-10-21 07:59:53 +00:00
Christopher Kohlhoff
4010cfe9de Add define to disable /dev/poll support.
[SVN r40109]
2007-10-17 08:20:30 +00:00
Christopher Kohlhoff
5af39ab4ef Make Windows XP the default target Windows version as the latest Windows
SDK doesn't support IPv6 for Windows 2000 targets.


[SVN r40108]
2007-10-17 07:58:38 +00:00
Christopher Kohlhoff
36edaaf006 Try changing the default target to Windows XP rather than Windows 2000 to see
effect on borland-5.9.2.


[SVN r39865]
2007-10-09 21:59:38 +00:00
Christopher Kohlhoff
7825a45960 Add missing "lib ipv6 ;" that's needed for HP-UX.
[SVN r39517]
2007-09-25 01:56:46 +00:00
Christopher Kohlhoff
0987067acc Add extra library 'ipv6' needed on HP-UX.
[SVN r39509]
2007-09-24 13:32:47 +00:00
Christopher Kohlhoff
2cd240ee88 Output error codes and error messages when a test fails.
[SVN r39505]
2007-09-24 13:21:49 +00:00
Christopher Kohlhoff
3e05da91c1 Use enum-based error code constants.
[SVN r39189]
2007-09-11 11:17:56 +00:00
Christopher Kohlhoff
9f53a075ff Define _WIN32_WINNT to suppress warnings. Add define necessary
for building with cygwin.


[SVN r39100]
2007-09-01 07:32:28 +00:00
Christopher Kohlhoff
df83f01414 Need to try binding the acceptor to test whether IPv6 is supported.
[SVN r39092]
2007-09-01 06:08:45 +00:00
Vladimir Prus
00be9349dc Revive V1 Jamfiles at Christopher's request
[SVN r38822]
2007-08-21 13:55:41 +00:00
Christopher Kohlhoff
0958213a44 Fix gcc warning about too few braces.
[SVN r38782]
2007-08-20 13:50:30 +00:00
Vladimir Prus
fb46c8923e Remove V1 Jamfiles
[SVN r38516]
2007-08-08 19:02:26 +00:00
Christopher Kohlhoff
1248ab625c Try to fix Borland C++ compile errors.
[SVN r37722]
2007-05-20 03:50:23 +00:00
Christopher Kohlhoff
df19961212 Fix compiler warnings.
[SVN r37682]
2007-05-13 08:23:08 +00:00
Christopher Kohlhoff
48f1ab2c57 Revert incorrect change to one of the test checks.
[SVN r37641]
2007-05-08 22:51:34 +00:00
Christopher Kohlhoff
7e98d31a1a Artifacts of new boostify.pl.
[SVN r37625]
2007-05-08 10:55:32 +00:00
Christopher Kohlhoff
d81cd3ba49 Fix another incorrect condition.
[SVN r37624]
2007-05-08 10:55:12 +00:00
Christopher Kohlhoff
29cb1736ba Fix test failure caused by incorrect condition check.
[SVN r37623]
2007-05-08 10:49:40 +00:00
Christopher Kohlhoff
7a1344d437 Additional error output to help diagnose test failures.
[SVN r37614]
2007-05-07 12:13:40 +00:00
Christopher Kohlhoff
72826c07c9 Add empty test cases to eliminate spurious failures when running all tests.
[SVN r37607]
2007-05-06 22:38:53 +00:00
Christopher Kohlhoff
046c9870fc Try to fix AIX compile error in tests.
[SVN r37391]
2007-04-07 09:01:23 +00:00
Christopher Kohlhoff
cc427bfc38 Need to specify Windows socket libraries with cw toolset.
[SVN r37045]
2007-02-23 02:28:24 +00:00
Christopher Kohlhoff
9abb1ff390 Fix test executable names.
[SVN r37044]
2007-02-23 02:22:10 +00:00
Christopher Kohlhoff
86ca754df7 Fix IPv6 detection.
[SVN r37039]
2007-02-23 01:34:33 +00:00
Christopher Kohlhoff
bafa5a3c7a Some fixes for Solaris, AIX and HP-UX.
[SVN r37020]
2007-02-20 13:19:53 +00:00
Christopher Kohlhoff
a61048b9d7 On Linux, the SO_DEBUG socket option can only be set by root.
[SVN r36760]
2007-01-20 02:04:56 +00:00
Christopher Kohlhoff
3e72c27764 Update copyright strings to include 2007.
[SVN r36757]
2007-01-19 01:57:08 +00:00
Christopher Kohlhoff
4ee1510c76 Update socket interfaces to match TR2 proposal.
[SVN r36675]
2007-01-09 13:54:51 +00:00
Christopher Kohlhoff
06402569d5 Update the behaviour of the asio::streambuf overloads of {async_}read and
{async_}read_until to match the TR2 proposal.


[SVN r36636]
2007-01-07 08:26:18 +00:00
Christopher Kohlhoff
f35b316f44 Add test cases for socket options.
[SVN r36597]
2007-01-06 10:26:17 +00:00
Christopher Kohlhoff
66dd4c3778 Rename const_buffer_container_1 to const_buffers_1 and
mutable_buffer_container_1 to mutable_buffers_1.


[SVN r36585]
2007-01-04 10:45:09 +00:00
Christopher Kohlhoff
a7209ee0be Rename io_service::interrupt() to io_service::stop().
[SVN r36583]
2007-01-04 09:22:02 +00:00
Christopher Kohlhoff
2ba4146527 Update socket option classes to match interface in TR2 proposal.
[SVN r36582]
2007-01-04 08:21:33 +00:00
Christopher Kohlhoff
2b4748aaaa Update copyright strings to include 2007.
[SVN r36581]
2007-01-04 05:53:07 +00:00
Christopher Kohlhoff
bc63a367f9 Add BBv2 support.
[SVN r36412]
2006-12-16 02:27:07 +00:00
Christopher Kohlhoff
8b56b8cf6d Remove the error::success constant since with the new error_code stuff
there is no unique value for success.


[SVN r36068]
2006-11-17 11:28:18 +00:00
Christopher Kohlhoff
7c9fe2a5ac Ensure that what gets thrown is the system_error exception.
[SVN r35947]
2006-11-09 11:21:43 +00:00
Christopher Kohlhoff
c7f491b73e Fix comment headers to match file names.
[SVN r35941]
2006-11-09 03:02:19 +00:00
Christopher Kohlhoff
852668d1da Change error handling to match TR2 proposal.
[SVN r35911]
2006-11-08 05:32:17 +00:00
Christopher Kohlhoff
da2ef49a00 Add max_size() function to basic_streambuf.
Make basic_io_object constructor protected.

Make a 0-length send or receive on a stream socket into a no-op.

Add cancel() function for cancelling asynchronous socket operations.
The Win32 implementation only works if all operations for the socket
have been issued from the same thread, otherwise it fails with
asio::error::not_supported.

Add workaround for an apparent Windows bug where using getpeername on
a socket accepted using AcceptEx will sometimes return an endpoint
that is all zeroes.

Make a strand last as long as it has any handlers to dispatch. Make
strand a nested class of io_service.

Add io_service() function to io_service::work to return a reference to
the io_service object on which the work is being performed. Renamed
io_service::service::owner() to io_service::service::io_service().

Unset linger object when socket objects are destroyed.

Rename asio_handler_dispatch to asio_handler_invoke.

Rename basic_socketbuf to basic_socket_streambuf.

Update ip::address_v4 and ip::address_v6 classes to match TR2
proposal.

Add run_one(), poll() and poll_one() functions to the io_service.

Remove need to #define FD_SETSIZE on Win32.

Add detection of incorrect inclusion of WinSock.h.

Fix some SSL bugs. Add ability to customise the SSL password callback
function.

Set the reuse_address option by default on acceptors.

The macros FIONREAD and FIONBIO are not integer constants on all
platforms, and so cannot be used as template arguments. Make the
corresponding I/O control commands into proper classes, not templates.

Fixes to better support *BSD platforms.

Add support for buffer debugging, if the standard library supports
iterator debugging (as MSVC8's standard lib does).

Ensure the IOCP queue is drained correctly at shutdown.

Move basic_resolver and resolver service into the ip namespace.

Fix some issues found by the inspect tool.


[SVN r35833]
2006-11-04 07:14:10 +00:00
Christopher Kohlhoff
0c65769b47 Add copyright notices.
[SVN r34726]
2006-07-25 11:04:06 +00:00
Christopher Kohlhoff
bfa9281e2c Fix error in socket_base_test rule.
[SVN r34534]
2006-07-14 13:07:47 +00:00
Christopher Kohlhoff
7027bf39d5 Change strand implementation so that dispatch will execute a handler
immediately if called from within the strand.

Add hook function for customising handler dispatch.

Need to use reinterpret_cast when testing for enable_connection_aborted
socket option, to allow non-int socket options to compile correctly.


[SVN r34464]
2006-07-05 05:48:10 +00:00
Christopher Kohlhoff
8075fa5a44 Extend socket_base unit test to catch socket option compile errors.
[SVN r34463]
2006-07-05 05:45:48 +00:00
Christopher Kohlhoff
dece5966f4 Fix Jamfiles to follow layout used by other libraries' tests.
[SVN r34334]
2006-06-18 08:05:06 +00:00
Christopher Kohlhoff
6c47408f2b Test that all ssl::stream functions compile.
[SVN r34333]
2006-06-18 08:03:35 +00:00
Christopher Kohlhoff
da0cf5f68a Initial asio checkin.
[SVN r34306]
2006-06-14 22:26:36 +00:00