Skip to content

Commit 800e1a3

Browse files
committed
fix: cast int64 to long long for %lld format specifier
1 parent e3fe759 commit 800e1a3

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

apps/cli/test.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ static void
3232
bitc_test_one_tx(struct btc_tx_desc *desc)
3333
{
3434
struct btc_msg_tx tx;
35-
char hashStr[80];
3635
uint256 hash;
3736
struct buff *buf;
3837
int res;
@@ -59,8 +58,7 @@ bitc_test_one_tx(struct btc_tx_desc *desc)
5958

6059
hash256_calc(buff_base(buf), buff_curlen(buf), &hash);
6160

62-
uint256_snprintf_reverse(hashStr, sizeof hashStr, &hash);
63-
log_info("TX: %s\n", hashStr);
61+
log_info("TX: %s\n", uint256_to_str(&hash));
6462

6563
ASSERT(res == 0);
6664
buff_free(buf);
@@ -168,7 +166,7 @@ bitc_crypt_test(void)
168166
s = crypt_set_key_from_passphrase(pass, &k, &count);
169167
ASSERT(s);
170168

171-
printf("num_iterations = %lld\n", count);
169+
printf("num_iterations = %lld\n", (long long)count);
172170

173171
s = crypt_encrypt(&k, sec, &cipher, &clen);
174172
ASSERT(s);

0 commit comments

Comments
 (0)