Skip to content

Commit

Permalink
optimized ssi code by storing binaries as the data chunks instead of …
Browse files Browse the repository at this point in the history
…lists of chars
  • Loading branch information
Claes Wikstrom committed Jun 4, 2013
1 parent 5878ac6 commit e41fec6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/yaws_server.erl
Expand Up @@ -3585,9 +3585,9 @@ delim_split_file(Del, Data, State, Ack) ->
case delim_split(Del, Del, Data, [], []) of
{H, []} when State == data ->
%% Ok, last chunk
lists:reverse([{data, H} | Ack]);
lists:reverse([{data, list_to_binary(H)} | Ack]);
{H, T} when State == data ->
delim_split_file(Del, T, var, [{data, H}|Ack]);
delim_split_file(Del, T, var, [{data, list_to_binary(H)}|Ack]);
{H, []} when State == var ->
lists:reverse([{var, H} | Ack]);
{H, T} when State == var ->
Expand Down

0 comments on commit e41fec6

Please sign in to comment.