From c75b49667eb15982db6b2da083f562a6055f5896 Mon Sep 17 00:00:00 2001 From: Robert Habermeier Date: Thu, 23 Mar 2017 14:49:02 +0100 Subject: [PATCH] workaround for #5008 --- ethcore/light/src/types/request/mod.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ethcore/light/src/types/request/mod.rs b/ethcore/light/src/types/request/mod.rs index f640687d5..0e11b8a7f 100644 --- a/ethcore/light/src/types/request/mod.rs +++ b/ethcore/light/src/types/request/mod.rs @@ -1051,8 +1051,9 @@ pub mod account { impl Decodable for Response { fn decode(rlp: &UntrustedRlp) -> Result { + let proof: Result<_, _> = rlp.at(0)?.iter().map(|x| x.as_list()).collect(); Ok(Response { - proof: rlp.list_at(0)?, + proof: proof?, nonce: rlp.val_at(1)?, balance: rlp.val_at(2)?, code_hash: rlp.val_at(3)?, @@ -1198,8 +1199,9 @@ pub mod storage { impl Decodable for Response { fn decode(rlp: &UntrustedRlp) -> Result { + let proof: Result<_, _> = rlp.at(0)?.iter().map(|x| x.as_list()).collect(); Ok(Response { - proof: rlp.list_at(0)?, + proof: proof?, value: rlp.val_at(1)?, }) }