Skip to content

Commit

Permalink
sys/ztimer64: fix build when PRIu64 is not defined
Browse files Browse the repository at this point in the history
  • Loading branch information
benpicco committed May 24, 2024
1 parent c46d75d commit a209ef1
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions sys/ztimer64/ztimer64.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,13 @@ void ztimer64_clock_print(const ztimer64_clock_t *clock)
const ztimer64_base_t *entry = clock->first;

while (entry) {
#ifdef PRIu64
printf("0x%08" PRIxPTR ":%" PRIu64 "\n", (uintptr_t)entry, entry->target);
#else
printf("0x%08" PRIxPTR ":%" PRIu32 "%s\n",
(uintptr_t)entry, (uint32_t)entry->target,
entry->target > UINT32_MAX ? " !TRUNC!" : "");
#endif
entry = entry->next;
}
puts("");
Expand Down

0 comments on commit a209ef1

Please sign in to comment.