Skip to content

Commit

Permalink
tx: fix a non-elements build warning
Browse files Browse the repository at this point in the history
  • Loading branch information
jgriffiths committed Jan 5, 2025
1 parent ef366ae commit 82e63b1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/transaction.c
Original file line number Diff line number Diff line change
Expand Up @@ -1969,7 +1969,9 @@ int wally_tx_get_vsize(const struct wally_tx *tx, size_t *written)
int wally_tx_get_elements_weight_discount(const struct wally_tx *tx,
uint32_t flags, size_t *written)
{
#ifdef BUILD_ELEMENTS
size_t i, n = 0, is_elements = 0;
#endif /* BUILD_ELEMENTS */

if (written)
*written = 0;
Expand Down Expand Up @@ -2004,7 +2006,7 @@ int wally_tx_get_elements_weight_discount(const struct wally_tx *tx,
}
}
*written = n;
#endif
#endif /* BUILD_ELEMENTS */
return WALLY_OK;
}
#endif /* WALLY_ABI_NO_ELEMENTS */
Expand Down

0 comments on commit 82e63b1

Please sign in to comment.