From 1b377b3d24596cbfb5b7ce20705dc9fce9aac0b6 Mon Sep 17 00:00:00 2001
From: Anders Svensson
Date: Thu, 28 Mar 2013 00:44:50 +0100
Subject: Make explicit local address to diameter_tcp:start/3 optional
Use the default address address (as selected by gen_tcp) if none is
configured, passing it in the new 'connected' message introduced by the
previous commit.
The corresponding update to diameter_sctp has to wait until problems
with inet:sockname/1 are resolved: the function currently only returns
one address, and sometimes {0,0,0,0}. See OTP-11018.
---
lib/diameter/doc/src/diameter_tcp.xml | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
(limited to 'lib/diameter/doc/src/diameter_tcp.xml')
diff --git a/lib/diameter/doc/src/diameter_tcp.xml b/lib/diameter/doc/src/diameter_tcp.xml
index 01c781d553..8e509aa829 100644
--- a/lib/diameter/doc/src/diameter_tcp.xml
+++ b/lib/diameter/doc/src/diameter_tcp.xml
@@ -1,5 +1,6 @@
start/3'>
gen_tcp:connect/3'>
start({Type, Ref}, Svc, [Opt])
- -> {ok, Pid, [LAddr]} | {error, Reason}
+ -> {ok, Pid}
+ | {ok, Pid, [LAddr]}
+ | {error, Reason}
Start a transport process.
Type = connect | accept
@@ -153,13 +156,14 @@ that will not be forthcoming, which will eventually cause the RFC 3539
watchdog to take down the connection.
-If the #diameter_service{} record has more than one
-Host-IP-Address and option ip is unspecified then the
-first of the these addresses is used as the local address.
-
-
-The returned local address list has length one.
-
+If an ip option is not specified then the first element of a
+non-empty Host-IP-Address list in Svc provides the local
+IP address.
+If neither is specified then the default address selected by &gen_tcp;
+is used.
+In all cases, the selected address is either returned from
+&start; or passed in a connected message over the transport
+interface.
--
cgit v1.2.3