Mercurial > code
changeset 438:5f837e40b569
Socket: cosmetic
author | David Demelier <markand@malikania.fr> |
---|---|
date | Thu, 22 Oct 2015 21:43:41 +0200 |
parents | 378699c81257 |
children | aaf975293996 |
files | C++/modules/Socket/Sockets.h |
diffstat | 1 files changed, 14 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/C++/modules/Socket/Sockets.h Thu Oct 22 21:38:28 2015 +0200 +++ b/C++/modules/Socket/Sockets.h Thu Oct 22 21:43:41 2015 +0200 @@ -905,9 +905,9 @@ * Predefine addressed to be used * ------------------------------------------------------------------ * - * - Ipv6 - * - Ipv4 - * - Local + * - Ipv6, + * - Ipv4, + * - Local. */ /* {{{ Addresses */ @@ -1135,8 +1135,9 @@ * Predefined types * ------------------------------------------------------------------ * - * - Tcp, for standard stream connections - * - Udp, for standard datagram connection + * - Tcp, for standard stream connections, + * - Udp, for standard datagram connections, + * - Tls, for secure stream connections. */ /* {{{ Types */ @@ -1454,6 +1455,8 @@ /* }}} */ +/* {{{ Tls */ + #if !defined(SOCKET_NO_SSL) /** @@ -1566,10 +1569,10 @@ template <typename Address> void connect(Socket<Address, Tls> &sc, const Address &address) { - // 1. Standard connect + /* 1. Standard connect */ Tcp::connect(sc.handle(), address.address(), address.length()); - // 2. OpenSSL handshake + /* 2. OpenSSL handshake */ auto ret = SSL_connect(m_ssl.get()); if (ret <= 0) { @@ -1687,12 +1690,15 @@ /* }}} */ +/* }}} */ + /* * Convenient helpers * ------------------------------------------------------------------ * * - SocketTcp<Address>, for TCP sockets, - * - SocketUdp<Address>, for UDP sockets + * - SocketUdp<Address>, for UDP sockets, + * - SocketTls<Address>, for secure TCP sockets. */ /* {{{ Helpers */