aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/cow_spdy.erl3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cow_spdy.erl b/src/cow_spdy.erl
index 4856afd..2dc1027 100644
--- a/src/cow_spdy.erl
+++ b/src/cow_spdy.erl
@@ -168,7 +168,8 @@ parse_headers(<< L1:32, Key:L1/binary, L2:32, Value:L2/binary, Rest/bits >>,
NbHeaders, Acc, SpAcc) ->
case Key of
<< $:, _/bits >> ->
- parse_headers(Rest, NbHeaders - 1, Acc, [{Key, Value}|SpAcc]);
+ parse_headers(Rest, NbHeaders - 1, Acc,
+ [{Key, Value}|lists:keydelete(Key, 1, SpAcc)]);
_ ->
parse_headers(Rest, NbHeaders - 1, [{Key, Value}|Acc], SpAcc)
end.