From 156a6d71064c80af554b4097389347ad4d1b0196 Mon Sep 17 00:00:00 2001 From: Alberto Bertogli Date: Sun, 6 Jan 2008 16:20:00 -0200 Subject: [PATCH] Add documentation and Misc/NEWS entry for TIPC support. --- Doc/library/socket.rst | 27 +++++++++++++++++++++++++++ Misc/NEWS | 2 ++ 2 files changed, 29 insertions(+), 0 deletions(-) diff --git a/Doc/library/socket.rst b/Doc/library/socket.rst index 40e6d19..0e3aa19 100644 --- a/Doc/library/socket.rst +++ b/Doc/library/socket.rst @@ -66,6 +66,27 @@ numeric address in *host* portion. .. versionadded:: 2.5 AF_NETLINK sockets are represented as pairs ``pid, groups``. +.. versionadded:: 2.6 + Linux-only support for TIPC is also available using the :const:`AF_TIPC` + address family. TIPC is an open, non-IP based networked protocol designed + for use in clustered computer environments. Addresses are represented by a + tuple, and the fields depend on the address type. The general tuple form is + ``(addr_type, v1, v2, v3 [, scope])``, where: + + - *addr_type* is one of TIPC_ADDR_NAMESEQ, TIPC_ADDR_NAME, or + TIPC_ADDR_ID. + - *scope* is one of TIPC_ZONE_SCOPE, TIPC_CLUSTER_SCOPE, and + TIPC_NODE_SCOPE. + - If *addr_type* is TIPC_ADDR_NAME, then *v1* is the server type, *v2* is + the port identifier, and *v3* should be 0. + + If *addr_type* is TIPC_ADDR_NAMESEQ, then *v1* is the server type, *v2* + is the lower port number, and *v3* is the upper port number. + + If *addr_type* is TIPC_ADDR_ID, then *v1* is the node, *v2* is the + reference, and *v3* should be set to 0. + + All errors raise exceptions. The normal exceptions for invalid argument types and out-of-memory conditions can be raised; errors related to socket or address semantics raise the error :exc:`socket.error`. @@ -169,6 +190,12 @@ The module :mod:`socket` exports the following constants and functions: .. versionadded:: 2.6 +.. data:: TIPC_* + + TIPC related constants, matching the ones exported by the C socket API. See + the TIPC documentation for more information. + + .. versionadded:: 2.6 .. data:: has_ipv6 diff --git a/Misc/NEWS b/Misc/NEWS index 4732113..719d448 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -342,6 +342,8 @@ Core and builtins Library ------- +- Issue #1646: Make socket support the TIPC protocol. + - Bug #1742: return os.curdir from os.path.relpath() if both arguments are equal instead of raising an exception. -- 1.5.4.rc2.1164.g6451