From 893c9820e4c2fe4ba8d29cba2e928dce9c717bcc Mon Sep 17 00:00:00 2001 From: BTChip Date: Mon, 17 Oct 2016 23:35:55 +0200 Subject: [PATCH] Handle to: destination length to detect a null contract address --- src_common/ethUstream.c | 1 + src_common/ethUstream.h | 1 + 2 files changed, 2 insertions(+) diff --git a/src_common/ethUstream.c b/src_common/ethUstream.c index cb322bf..d93ba94 100644 --- a/src_common/ethUstream.c +++ b/src_common/ethUstream.c @@ -202,6 +202,7 @@ static void processTo(txContext_t *context) { copySize); } if (context->currentFieldPos == context->currentFieldLength) { + context->content->destinationLength = context->currentFieldLength; context->currentField++; context->processingField = false; } diff --git a/src_common/ethUstream.h b/src_common/ethUstream.h index 3d96d0a..bb3658f 100644 --- a/src_common/ethUstream.h +++ b/src_common/ethUstream.h @@ -51,6 +51,7 @@ typedef struct txContent_t { txInt256_t startgas; txInt256_t value; uint8_t destination[20]; + uint8_t destinationLength; } txContent_t; typedef struct txContext_t {