Skip to content
This repository was archived by the owner on Dec 26, 2022. It is now read-only.

Commit 122a4ab

Browse files
committed
fix: Incorrect txn hash in find_transaction_object response
1 parent 0ce6158 commit 122a4ab

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

accelerator/common_core.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -318,6 +318,8 @@ int ta_get_transaction_object(const iota_client_service_t* const service,
318318
retcode_t ret = RC_OK;
319319
flex_trit_t tx_trits[FLEX_TRIT_SIZE_8019];
320320
flex_trit_t hash_trits[NUM_TRITS_HASH];
321+
flex_trits_from_trytes(hash_trits, NUM_TRITS_HASH, (const tryte_t*)req,
322+
NUM_TRYTES_HASH, NUM_TRYTES_HASH);
321323
char cache_value[FLEX_TRIT_SIZE_8019] = {0};
322324

323325
// get raw transaction data of transaction hashes
@@ -335,8 +337,6 @@ int ta_get_transaction_object(const iota_client_service_t* const service,
335337
tx_trits, NUM_TRITS_SERIALIZED_TRANSACTION, (const tryte_t*)cache_value,
336338
NUM_TRYTES_SERIALIZED_TRANSACTION, NUM_TRYTES_SERIALIZED_TRANSACTION);
337339
} else {
338-
flex_trits_from_trytes(hash_trits, NUM_TRITS_HASH, (const tryte_t*)req,
339-
NUM_TRYTES_HASH, NUM_TRYTES_HASH);
340340
ret = hash243_queue_push(&get_trytes_req->hashes, hash_trits);
341341
if (ret) {
342342
goto done;

0 commit comments

Comments
 (0)