From adcf5eb5f43ed83a0bb9aacdffa155c0b02ed0c3 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Thu, 5 May 2011 11:25:53 +0200 Subject: Spec corrections --- lib/ssl/doc/src/ssl.xml | 10 ++++------ lib/ssl/src/ssl.erl | 8 ++++---- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index f3164cdb46..0da6bbee5b 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -53,13 +53,11 @@

The following data types are used in the functions below:

-

boolean() = true | false

- -

property() = atom()

- +

boolean() = true | false

+

option() = socketoption() | ssloption() | transportoption()

-

socketoption() = [{property(), term()}] - defaults to +

socketoption() = proplists:property() - The default socket options are [{mode,list},{packet, 0},{header, 0},{active, true}].

@@ -488,7 +486,7 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom()} | Get the value of the specified options. Socket = sslsocket() - OptionNames = [property()] + OptionNames = [atom()]

Get the value of the specified socket options, if no diff --git a/lib/ssl/src/ssl.erl b/lib/ssl/src/ssl.erl index c3e0bcf466..380c59b058 100644 --- a/lib/ssl/src/ssl.erl +++ b/lib/ssl/src/ssl.erl @@ -402,9 +402,9 @@ cipher_suites(openssl) -> [ssl_cipher:openssl_suite_name(S) || S <- ssl_cipher:suites(Version)]. %%-------------------------------------------------------------------- --spec getopts(#sslsocket{}, [atom()]) -> {ok, [{atom(), term()}]}| {error, reason()}. +-spec getopts(#sslsocket{}, [atom()]) -> {ok, [{atom(), term()}]} | {error, reason()}. %% -%% Description: +%% Description: Gets options %%-------------------------------------------------------------------- getopts(#sslsocket{fd = new_ssl, pid = Pid}, OptTags) when is_pid(Pid) -> ssl_connection:get_opts(Pid, OptTags); @@ -415,9 +415,9 @@ getopts(#sslsocket{} = Socket, Options) -> ssl_broker:getopts(Socket, Options). %%-------------------------------------------------------------------- --spec setopts(#sslsocket{}, [{atom(), term()}]) -> ok | {error, reason()}. +-spec setopts(#sslsocket{}, [proplist:property()]) -> ok | {error, reason()}. %% -%% Description: +%% Description: Sets options %%-------------------------------------------------------------------- setopts(#sslsocket{fd = new_ssl, pid = Pid}, Opts0) when is_pid(Pid) -> Opts = proplists:expand([{binary, [{mode, binary}]}, -- cgit v1.2.3