Skip to content

Commit 994d6da

Browse files
committed
Fix a problem with streams.
Upgrade cowboy to 2.9.0
1 parent 11526b5 commit 994d6da

File tree

3 files changed

+23
-17
lines changed

3 files changed

+23
-17
lines changed

rebar.config

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
%%-*- mode: erlang -*-
22

3-
{require_min_otp_vsn, "22"}.
3+
{require_min_otp_vsn, "22.3"}.
44

55
{plugins, [rebar3_hex]}.
66

77
{deps, [
8-
{zotonic_stdlib, "1.2.11"},
9-
{cowboy, "2.8.0"}
8+
{zotonic_stdlib, "1.5.9"},
9+
{cowboy, "2.9.0"}
1010
]}.
1111

1212
{profiles, [

rebar.lock

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
{"1.2.0",
2-
[{<<"cowboy">>,{pkg,<<"cowboy">>,<<"2.8.0">>},0},
3-
{<<"cowlib">>,{pkg,<<"cowlib">>,<<"2.9.1">>},1},
4-
{<<"ranch">>,{pkg,<<"ranch">>,<<"1.7.1">>},1},
5-
{<<"zotonic_stdlib">>,{pkg,<<"zotonic_stdlib">>,<<"1.2.11">>},0}]}.
2+
[{<<"cowboy">>,{pkg,<<"cowboy">>,<<"2.9.0">>},0},
3+
{<<"cowlib">>,{pkg,<<"cowlib">>,<<"2.11.0">>},1},
4+
{<<"ranch">>,{pkg,<<"ranch">>,<<"1.8.0">>},1},
5+
{<<"ssl_verify_fun">>,{pkg,<<"ssl_verify_fun">>,<<"1.1.6">>},2},
6+
{<<"tls_certificate_check">>,{pkg,<<"tls_certificate_check">>,<<"1.8.0">>},1},
7+
{<<"zotonic_stdlib">>,{pkg,<<"zotonic_stdlib">>,<<"1.5.9">>},0}]}.
68
[
79
{pkg_hash,[
8-
{<<"cowboy">>, <<"F3DC62E35797ECD9AC1B50DB74611193C29815401E53BAC9A5C0577BD7BC667D">>},
9-
{<<"cowlib">>, <<"61A6C7C50CF07FDD24B2F45B89500BB93B6686579B069A89F88CB211E1125C78">>},
10-
{<<"ranch">>, <<"6B1FAB51B49196860B733A49C07604465A47BDB78AA10C1C16A3D199F7F8C881">>},
11-
{<<"zotonic_stdlib">>, <<"CAB477495E4C1D265118A4E71780D6A5C571ABB3155F2D7C2A84C5AC915A69C6">>}]},
10+
{<<"cowboy">>, <<"865DD8B6607E14CF03282E10E934023A1BD8BE6F6BACF921A7E2A96D800CD452">>},
11+
{<<"cowlib">>, <<"0B9FF9C346629256C42EBE1EEB769A83C6CB771A6EE5960BD110AB0B9B872063">>},
12+
{<<"ranch">>, <<"8C7A100A139FD57F17327B6413E4167AC559FBC04CA7448E9BE9057311597A1D">>},
13+
{<<"ssl_verify_fun">>, <<"CF344F5692C82D2CD7554F5EC8FD961548D4FD09E7D22F5B62482E5AEAEBD4B0">>},
14+
{<<"tls_certificate_check">>, <<"8A41A435C8055CB11D1D0AC96B34F48377D49FEA2782D70EABCF8946539946A3">>},
15+
{<<"zotonic_stdlib">>, <<"64BFCBBF42511E22BBFF254609C68E19D3458924EE7E357E03190C5CC29A204B">>}]},
1216
{pkg_hash_ext,[
13-
{<<"cowboy">>, <<"4643E4FBA74AC96D4D152C75803DE6FAD0B3FA5DF354C71AFDD6CBEEB15FAC8A">>},
14-
{<<"cowlib">>, <<"E4175DC240A70D996156160891E1C62238EDE1729E45740BDD38064DAD476170">>},
15-
{<<"ranch">>, <<"451D8527787DF716D99DC36162FCA05934915DB0B6141BBDAC2EA8D3C7AFC7D7">>},
16-
{<<"zotonic_stdlib">>, <<"F3AE8AA22E5ECF3A8D329283CE24A8A6F9340004BDF59915E4E373FCB6F22FB5">>}]}
17+
{<<"cowboy">>, <<"2C729F934B4E1AA149AFF882F57C6372C15399A20D54F65C8D67BEF583021BDE">>},
18+
{<<"cowlib">>, <<"2B3E9DA0B21C4565751A6D4901C20D1B4CC25CBB7FD50D91D2AB6DD287BC86A9">>},
19+
{<<"ranch">>, <<"49FBCFD3682FAB1F5D109351B61257676DA1A2FDBE295904176D5E521A2DDFE5">>},
20+
{<<"ssl_verify_fun">>, <<"BDB0D2471F453C88FF3908E7686F86F9BE327D065CC1EC16FA4540197EA04680">>},
21+
{<<"tls_certificate_check">>, <<"5211FD87B4FEFAA77F2DE1F03479CBC4EE8312738A21B9B905253674468928F2">>},
22+
{<<"zotonic_stdlib">>, <<"AEBFC5C41989FE76458C3739269021D144454B94915F18B9E7A6249CA2F7CF0F">>}]}
1723
].

src/cowmachine_response.erl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,14 +103,14 @@ send_response_bodyfun({device, Length, IO}, Code, all, Context) ->
103103
Writer = fun(FunContext) ->
104104
send_device_body(FunContext, Length, IO),
105105
_ = file:close(IO),
106-
{fin, FunContext}
106+
FunContext
107107
end,
108108
start_response_stream(Code, Length, Writer, all, Context);
109109
send_response_bodyfun({device, _Length, IO}, Code, Parts, Context) ->
110110
Writer = fun(FunContext, WParts) ->
111111
FunContext1 = send_device_body_parts(FunContext, WParts, IO),
112112
_ = file:close(IO),
113-
{fin, FunContext1}
113+
FunContext1
114114
end,
115115
start_response_stream(Code, undefined, Writer, Parts, Context);
116116
% File

0 commit comments

Comments
 (0)