diff options
author | Loïc Hoguin <[email protected]> | 2019-05-09 10:43:25 +0200 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2019-05-09 10:47:15 +0200 |
commit | 3ea575d8682560fc02d5583cbf2837e2f2f43e9f (patch) | |
tree | a20024277c5bad93fd05d9a32013ecabfeddd485 /examples | |
parent | e92171a8f80755dad795691ad9e07807212d0d1c (diff) | |
download | ranch-3ea575d8682560fc02d5583cbf2837e2f2f43e9f.tar.gz ranch-3ea575d8682560fc02d5583cbf2837e2f2f43e9f.tar.bz2 ranch-3ea575d8682560fc02d5583cbf2837e2f2f43e9f.zip |
Remove Socket argument from ranch_protocol:start_link
Diffstat (limited to 'examples')
-rw-r--r-- | examples/tcp_echo/src/echo_protocol.erl | 4 | ||||
-rw-r--r-- | examples/tcp_reverse/src/reverse_protocol.erl | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/examples/tcp_echo/src/echo_protocol.erl b/examples/tcp_echo/src/echo_protocol.erl index d8944c6..c07b424 100644 --- a/examples/tcp_echo/src/echo_protocol.erl +++ b/examples/tcp_echo/src/echo_protocol.erl @@ -3,10 +3,10 @@ -module(echo_protocol). -behaviour(ranch_protocol). --export([start_link/4]). +-export([start_link/3]). -export([init/3]). -start_link(Ref, _Socket, Transport, Opts) -> +start_link(Ref, Transport, Opts) -> Pid = spawn_link(?MODULE, init, [Ref, Transport, Opts]), {ok, Pid}. diff --git a/examples/tcp_reverse/src/reverse_protocol.erl b/examples/tcp_reverse/src/reverse_protocol.erl index 91a5b95..2865a60 100644 --- a/examples/tcp_reverse/src/reverse_protocol.erl +++ b/examples/tcp_reverse/src/reverse_protocol.erl @@ -5,7 +5,7 @@ -behaviour(ranch_protocol). %% API. --export([start_link/4]). +-export([start_link/3]). %% gen_statem. -export([callback_mode/0]). @@ -20,7 +20,7 @@ %% API. -start_link(Ref, _Socket, Transport, Opts) -> +start_link(Ref, Transport, Opts) -> {ok, proc_lib:spawn_link(?MODULE, init, [{Ref, Transport, Opts}])}. %% gen_statem. |