From 8de1e4ac6a69cdbc8a67157688f724d63e78508d Mon Sep 17 00:00:00 2001 From: Linus Nordberg Date: Mon, 11 May 2015 11:21:55 +0200 Subject: Fix CATLFISH-45. https://project.nordu.net/browse/CATLFISH-45 --- src/catlfish.erl | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/catlfish.erl b/src/catlfish.erl index d1f4425..5865626 100644 --- a/src/catlfish.erl +++ b/src/catlfish.erl @@ -243,13 +243,11 @@ init_cache_table() -> end, ets:new(?CACHE_TABLE, [set, public, named_table]). +deserialise_extra_data(<<>>) -> + []; deserialise_extra_data(ExtraData) -> - case decode_tls_vector(ExtraData, 3) of - {E, <<>>} -> - [E]; - {E, Rest} -> - [E | deserialise_extra_data(Rest)] - end. + {E, Rest} = decode_tls_vector(ExtraData, 3), + [E | deserialise_extra_data(Rest)]. chain_from_entry(Entry) -> {MTLText, ExtraDataPacked} = unpack_entry(Entry), -- cgit v1.1