aboutsummaryrefslogtreecommitdiff
path: root/src/test/test_dir.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-07-03 10:33:50 -0400
committerNick Mathewson <nickm@torproject.org>2018-07-03 10:33:50 -0400
commit52884f56d43670f1960d9354ccc3ace9a048e283 (patch)
tree298e3f789a003cc9f08e4f8e24bf93964711b60c /src/test/test_dir.c
parentcf0b07c2e5284325fb89f2c8ee3ad99f5ed02195 (diff)
downloadtor-52884f56d43670f1960d9354ccc3ace9a048e283.tar.gz
tor-52884f56d43670f1960d9354ccc3ace9a048e283.zip
Replace U64_LITERAL with the standard UINT64_C
Diffstat (limited to 'src/test/test_dir.c')
-rw-r--r--src/test/test_dir.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/test/test_dir.c b/src/test/test_dir.c
index 498ecf942e..70a8bc50ef 100644
--- a/src/test/test_dir.c
+++ b/src/test/test_dir.c
@@ -2102,7 +2102,7 @@ test_vrs_for_v3ns(vote_routerstatus_t *vrs, int voter, time_t now)
tt_int_op(rs->or_port,OP_EQ, 443);
tt_int_op(rs->dir_port,OP_EQ, 8000);
/* no flags except "running" (16) and "v2dir" (64) and "valid" (128) */
- tt_u64_op(vrs->flags, OP_EQ, U64_LITERAL(0xd0));
+ tt_u64_op(vrs->flags, OP_EQ, UINT64_C(0xd0));
} else if (tor_memeq(rs->identity_digest,
"\x5\x5\x5\x5\x5\x5\x5\x5\x5\x5\x5\x5\x5\x5\x5\x5"
"\x5\x5\x5\x5",
@@ -2128,10 +2128,10 @@ test_vrs_for_v3ns(vote_routerstatus_t *vrs, int voter, time_t now)
tt_int_op(rs->ipv6_orport,OP_EQ, 4711);
if (voter == 1) {
/* all except "authority" (1) */
- tt_u64_op(vrs->flags, OP_EQ, U64_LITERAL(254));
+ tt_u64_op(vrs->flags, OP_EQ, UINT64_C(254));
} else {
/* 1023 - authority(1) - madeofcheese(16) - madeoftin(32) */
- tt_u64_op(vrs->flags, OP_EQ, U64_LITERAL(974));
+ tt_u64_op(vrs->flags, OP_EQ, UINT64_C(974));
}
} else if (tor_memeq(rs->identity_digest,
"\x33\x33\x33\x33\x33\x33\x33\x33\x33\x33"
@@ -2941,8 +2941,8 @@ test_dir_scale_bw(void *testdata)
for (i=0; i<8; ++i) {
total += vals_u64[i];
}
- tt_assert(total >= (U64_LITERAL(1)<<60));
- tt_assert(total <= (U64_LITERAL(1)<<62));
+ tt_assert(total >= (UINT64_C(1)<<60));
+ tt_assert(total <= (UINT64_C(1)<<62));
for (i=0; i<8; ++i) {
/* vals[2].u64 is the scaled value of 1.0 */