From b79e9fbeb4eb5e80eb23f60ef71371addbcb2355 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Sat, 1 Oct 2011 18:54:43 +0200 Subject: Get rid of a binary construct in cowboy_http_req Thanks to @klaar for pointing it out in ticket #59. --- src/cowboy_http_req.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/cowboy_http_req.erl b/src/cowboy_http_req.erl index 1ea656f..272c8a8 100644 --- a/src/cowboy_http_req.erl +++ b/src/cowboy_http_req.erl @@ -346,7 +346,7 @@ response_head(Code, Headers, DefaultHeaders) -> Headers2 = [{header_to_binary(Key), Value} || {Key, Value} <- Headers], Headers3 = lists:keysort(1, Headers2), Headers4 = lists:ukeymerge(1, Headers3, DefaultHeaders), - Headers5 = [<< Key/binary, ": ", Value/binary, "\r\n" >> + Headers5 = [[Key, <<": ">>, Value, <<"\r\n">>] || {Key, Value} <- Headers4], [StatusLine, Headers5, <<"\r\n">>]. -- cgit v1.2.3